Skip to content

Commit a4572c3

Browse files
committed
Merge branch 'main' of https://github.com/microsoft/durabletask-dotnet into wangbill/schedule-poc
2 parents 2ee50e1 + ccf9bee commit a4572c3

File tree

69 files changed

+3191
-371
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+3191
-371
lines changed

.github/workflows/validate-build.yml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,16 +14,14 @@ on:
1414

1515
env:
1616
solution: Microsoft.DurableTask.sln
17-
config: Release
17+
config: release
1818

1919
jobs:
2020
build:
21-
runs-on: ubuntu-latest
21+
runs-on: windows-latest
2222

2323
steps:
2424
- uses: actions/checkout@v3
25-
with:
26-
submodules: true
2725

2826
- name: Setup .NET 6.0
2927
uses: actions/setup-dotnet@v3
@@ -36,19 +34,19 @@ jobs:
3634
global-json-file: global.json
3735

3836
- name: Restore dependencies
39-
run: dotnet restore $solution
37+
run: dotnet restore $env:solution
4038

4139
- name: Build
42-
run: dotnet build $solution --configuration $config --no-restore -p:FileVersionRevision=$GITHUB_RUN_NUMBER -p:ContinuousIntegrationBuild=true
40+
run: dotnet build $env:solution --configuration $env:config --no-restore -p:FileVersionRevision=$env:GITHUB_RUN_NUMBER
4341

4442
- name: Test
45-
run: dotnet test $solution --configuration $config --no-build --verbosity normal
43+
run: dotnet test $env:solution --configuration $env:config --no-build --verbosity normal
4644

4745
- name: Pack
48-
run: dotnet pack $solution --configuration $config --no-build
46+
run: dotnet pack $env:solution --configuration $env:config --no-build
4947

5048
- name: Upload
51-
uses: actions/upload-artifact@v3
49+
uses: actions/upload-artifact@v4
5250
with:
5351
name: pkg
5452
path: out/pkg

.gitmodules

Lines changed: 0 additions & 3 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,21 @@
11
# Changelog
22

3+
## vNext
4+
5+
### Microsoft.DurableTask.Client
6+
7+
- Add new `IDurableTaskClientBuilder AddDurableTaskClient(IServiceCollection, string?)` API
8+
9+
### Microsoft.DurableTask.Worker
10+
11+
- Add new `IDurableTaskWorkerBuilder AddDurableTaskWorker(IServiceCollection, string?)` API
12+
- Add support for work item history streaming
13+
14+
### Microsoft.DurableTask.Grpc
15+
16+
- Replace submodule for proto files with download script for easier maintenance
17+
- Update to latest proto files
18+
319
## v1.5.0
420

521
- Implement work item completion tokens for standalone worker scenarios ([#359](https://github.com/microsoft/durabletask-dotnet/pull/359))

Directory.Build.props

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,9 @@
3636
<StrongNamePublicKey>00240000048000009400000006020000002400005253413100040000010001000505410141442095e0b0466df68ac32d158abdf0bd9cf26407d7a9d20b93656530556f23979f20b067628b9baee75fc6bba5c349519585a2852c1843bc61d74c4cbf9d80429cbdcbf609ea70fd62061eb65f40a6c9d505dd71cb119ef51f589a014d3b56159abbc38825fafbd119b6e97ebd9a5f3862a5c06220c680a6ac9eec</StrongNamePublicKey>
3737
</PropertyGroup>
3838

39+
<PropertyGroup Condition="'$(ContinuousIntegrationBuild)' == ''">
40+
<ContinuousIntegrationBuild Condition="'$(CI)' == 'true'">true</ContinuousIntegrationBuild> <!-- GitHub actions -->
41+
<ContinuousIntegrationBuild Condition="'$(TF_BUILD)' == 'true'">true</ContinuousIntegrationBuild> <!-- Azure Devops -->
42+
</PropertyGroup>
43+
3944
</Project>

Microsoft.DurableTask.sln

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ EndProject
8484
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Shared.AzureManaged.Tests", "test\Shared\AzureManaged.Tests\Shared.AzureManaged.Tests.csproj", "{3272C041-F81D-4C85-A4FB-2A700B5A7A9D}"
8585
EndProject
8686
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ScheduleDemo", "samples\ScheduleDemo\ScheduleDemo.csproj", "{FF37BC53-8EC1-4673-915B-E59B38E286DF}"
87+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConsoleAppMinimal", "samples\ConsoleAppMinimal\ConsoleAppMinimal.csproj", "{B48FACA9-A328-452A-BFAE-C4F60F9C7024}"
8788
EndProject
8889
Global
8990
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -219,10 +220,10 @@ Global
219220
{3272C041-F81D-4C85-A4FB-2A700B5A7A9D}.Debug|Any CPU.Build.0 = Debug|Any CPU
220221
{3272C041-F81D-4C85-A4FB-2A700B5A7A9D}.Release|Any CPU.ActiveCfg = Release|Any CPU
221222
{3272C041-F81D-4C85-A4FB-2A700B5A7A9D}.Release|Any CPU.Build.0 = Release|Any CPU
222-
{FF37BC53-8EC1-4673-915B-E59B38E286DF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
223-
{FF37BC53-8EC1-4673-915B-E59B38E286DF}.Debug|Any CPU.Build.0 = Debug|Any CPU
224-
{FF37BC53-8EC1-4673-915B-E59B38E286DF}.Release|Any CPU.ActiveCfg = Release|Any CPU
225-
{FF37BC53-8EC1-4673-915B-E59B38E286DF}.Release|Any CPU.Build.0 = Release|Any CPU
223+
{B48FACA9-A328-452A-BFAE-C4F60F9C7024}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
224+
{B48FACA9-A328-452A-BFAE-C4F60F9C7024}.Debug|Any CPU.Build.0 = Debug|Any CPU
225+
{B48FACA9-A328-452A-BFAE-C4F60F9C7024}.Release|Any CPU.ActiveCfg = Release|Any CPU
226+
{B48FACA9-A328-452A-BFAE-C4F60F9C7024}.Release|Any CPU.Build.0 = Release|Any CPU
226227
EndGlobalSection
227228
GlobalSection(SolutionProperties) = preSolution
228229
HideSolutionNode = FALSE
@@ -264,7 +265,7 @@ Global
264265
{1E5C2E83-7B6B-425A-9C9B-0B887D273B12} = {51DC98A3-0193-4C66-964B-C26C748E25B6}
265266
{CECADDB5-E30A-4CE2-8604-9AC596D4A2DC} = {E5637F81-2FB9-4CD7-900D-455363B142A7}
266267
{3272C041-F81D-4C85-A4FB-2A700B5A7A9D} = {CECADDB5-E30A-4CE2-8604-9AC596D4A2DC}
267-
{FF37BC53-8EC1-4673-915B-E59B38E286DF} = {EFF7632B-821E-4CFC-B4A0-ED4B24296B17}
268+
{B48FACA9-A328-452A-BFAE-C4F60F9C7024} = {EFF7632B-821E-4CFC-B4A0-ED4B24296B17}
268269
EndGlobalSection
269270
GlobalSection(ExtensibilityGlobals) = postSolution
270271
SolutionGuid = {AB41CB55-35EA-4986-A522-387AB3402E71}

README.md

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,9 @@
33
[![Build status](https://github.com/microsoft/durabletask-dotnet/workflows/Validate%20Build/badge.svg)](https://github.com/microsoft/durabletask-dotnet/actions?workflow=Validate+Build)
44
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)
55

6-
The Durable Task .NET Client SDK is a .NET Standard 2.0 library for implementing Durable Task orchestrations and activities. It's specifically designed to connect to a "sidecar" process, such as the [Azure Functions .NET Isolated host](https://docs.microsoft.com/azure/azure-functions/dotnet-isolated-process-guide), a special purpose sidecar container, or potentially even [Dapr](https://github.com/dapr/dapr/issues/4576).
6+
The Durable Task .NET SDK is a standalone .NET library for implementing Durable Task orchestrations, activities, and entities. It's specifically designed to connect to a "sidecar" process, such as the [Azure Functions .NET Isolated host](https://docs.microsoft.com/azure/azure-functions/dotnet-isolated-process-guide), or a managed Azure endpoint, such as the [Durable Task Scheduler](https://techcommunity.microsoft.com/blog/appsonazureblog/announcing-limited-early-access-of-the-durable-task-scheduler-for-azure-durable-/4286526) (preview).
77

8-
If you're looking to run fully self-hosted Durable Task Framework apps, see https://github.com/azure/durabletask.
9-
10-
*Current Release*: [v1.0.0](https://github.com/microsoft/durabletask-dotnet/releases/tag/v1.0.0)
8+
> This project is different from the [Durable Task Framework](https://github.com/azure/durabletask), which supports running fully self-hosted apps using a storage-based backend like Azure Storage or MSSQL.
119
1210
## NuGet packages
1311

@@ -19,9 +17,11 @@ The following nuget packages are available for download.
1917
| Abstractions SDK | [![NuGet version (Microsoft.DurableTask.Abstractions)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Abstractions)](https://www.nuget.org/packages/Microsoft.DurableTask.Abstractions/) | Contains base abstractions for Durable. Useful for writing re-usable libraries independent of the chosen worker or client. |
2018
| Client SDK | [![NuGet version (Microsoft.DurableTask.Client)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Client)](https://www.nuget.org/packages/Microsoft.DurableTask.Client/) | Contains the core client logic for interacting with a Durable backend. |
2119
| Client.Grpc SDK | [![NuGet version (Microsoft.DurableTask.Client.Grpc)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Client.Grpc)](https://www.nuget.org/packages/Microsoft.DurableTask.Client.Grpc/) | The gRPC client implementation. |
20+
| Client.AzureManaged SDK | [![NuGet version (Microsoft.DurableTask.Worker.AzureManaged)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Worker.AzureManaged)](https://www.nuget.org/packages/Microsoft.DurableTask.Worker.AzureManaged/) | The client implementation for use with the [Durable Task Scheduler](https://techcommunity.microsoft.com/blog/appsonazureblog/announcing-limited-early-access-of-the-durable-task-scheduler-for-azure-durable-/4286526) (preview). |
2221
| Worker SDK | [![NuGet version (Microsoft.DurableTask.Worker)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Worker)](https://www.nuget.org/packages/Microsoft.DurableTask.Worker/) | Contains the core worker logic for having a `IHostedService` to process durable tasks. |
23-
| Worker.Grpc SDK | [![NuGet version (Microsoft.DurableTask.Worker.Grpc)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Worker.Grpc)](https://www.nuget.org/packages/Microsoft.DurableTask.Worker.Grpc/) | The gRPC worker implementation.
24-
| Source Generators | [![NuGet version (Microsoft.DurableTask.Generators)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Generators)](https://www.nuget.org/packages/Microsoft.DurableTask.Generators/) | DurableTask source generators. |
22+
| Worker.Grpc SDK | [![NuGet version (Microsoft.DurableTask.Worker.Grpc)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Worker.Grpc)](https://www.nuget.org/packages/Microsoft.DurableTask.Worker.Grpc/) | The gRPC worker implementation. |
23+
| Worker.AzureManaged SDK | [![NuGet version (Microsoft.DurableTask.Worker.AzureManaged)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Worker.AzureManaged)](https://www.nuget.org/packages/Microsoft.DurableTask.Worker.AzureManaged/) | The worker implementation for use with the [Durable Task Scheduler](https://techcommunity.microsoft.com/blog/appsonazureblog/announcing-limited-early-access-of-the-durable-task-scheduler-for-azure-durable-/4286526) (preview). |
24+
| Source Generators | [![NuGet version (Microsoft.DurableTask.Generators)](https://img.shields.io/nuget/vpre/Microsoft.DurableTask.Generators)](https://www.nuget.org/packages/Microsoft.DurableTask.Generators/) | Source generators for type-safe orchestration and activity invocations. |
2525

2626
## Usage with Azure Functions
2727

@@ -32,7 +32,7 @@ To get started, add the [Microsoft.Azure.Functions.Worker.Extensions.DurableTask
3232
```xml
3333
<ItemGroup>
3434
<PackageReference Include="Microsoft.Azure.Functions.Worker" Version="1.10.0" />
35-
<PackageReference Include="Microsoft.Azure.Functions.Worker.Extensions.DurableTask" Version="1.0.0" />
35+
<PackageReference Include="Microsoft.Azure.Functions.Worker.Extensions.DurableTask" Version="1.2.2" />
3636
<PackageReference Include="Microsoft.Azure.Functions.Worker.Extensions.Http" Version="3.0.13" />
3737
<PackageReference Include="Microsoft.Azure.Functions.Worker.Sdk" Version="1.7.0" OutputItemType="Analyzer" />
3838
<PackageReference Include="Microsoft.DurableTask.Generators" Version="1.0.0-preview.1" OutputItemType="Analyzer" />
@@ -159,17 +159,15 @@ You can find the full sample file, including detailed comments, at [samples/Azur
159159

160160
This SDK is *not* compatible with Durable Functions for the .NET *in-process* worker. It only works with the newer out-of-process .NET Isolated worker.
161161

162-
There are also several features that aren't yet available:
162+
## Usage with the Durable Task Scheduler
163163

164-
* Durable Entities is not yet supported.
165-
* APIs for calling HTTP endpoints are not yet available.
166-
* Several instance management APIs are not yet implemented.
164+
The Durable Task Scheduler for Azure Functions is a managed backend that is currently in preview. Durable Functions apps can use the Durable Task Scheduler as one of its [supported storage providers](https://learn.microsoft.com/azure/azure-functions/durable/durable-functions-storage-providers).
167165

168-
## Obtaining the Protobuf definitions
166+
This SDK can also be used with the Durable Task Scheduler directly, without any Durable Functions dependency. To get started, sign up for the [Durable Task Scheduler private preview](https://techcommunity.microsoft.com/blog/appsonazureblog/announcing-limited-early-access-of-the-durable-task-scheduler-for-azure-durable-/4286526) and follow the instructions to create a new Durable Task Scheduler instance. Once granted access to the private preview GitHub repository, you can find samples and documentation for getting started [here](https://github.com/Azure/Azure-Functions-Durable-Task-Scheduler-Private-Preview/tree/main/samples/portable-sdk/dotnet/AspNetWebApp#readme).
169167

170-
This project utilizes git submodules to obtain Protobuf definitions from [durabletask-protobuf](https://github.com/microsoft/durabletask-protobuf). You will need to obtain these to build the project.
168+
## Obtaining the Protobuf definitions
171169

172-
To get the definitions, run `git submodule update --init --recursive`
170+
This project utilizes protobuf definitions from [durabletask-protobuf](https://github.com/microsoft/durabletask-protobuf), which are copied (vendored) into this repository under the `src/Grpc` directory. See the corresponding [README.md](./src/Grpc/README.md) for more information about how to update the protobuf definitions.
173171

174172
## Contributing
175173

azure-pipelines-release.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ variables:
2828

2929
steps:
3030
- checkout: self
31-
submodules: true
3231

3332
- task: UseDotNet@2
3433
displayName: 'Install .NET 6 SDK (ESRP)' # This is needed for ESRP.

eng/proto

Lines changed: 0 additions & 1 deletion
This file was deleted.

eng/templates/build.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ jobs:
2424

2525
steps:
2626
- checkout: self
27-
submodules: true
2827

2928
- task: UseDotNet@2
3029
displayName: 'Install .NET 6 SDK (ESRP)' # This is needed for ESRP.

samples/ConsoleApp/ConsoleApp.csproj

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,24 @@
22

33
<PropertyGroup>
44
<OutputType>Exe</OutputType>
5-
<TargetFramework>net6.0</TargetFramework>
5+
<TargetFramework>net8.0</TargetFramework>
66
<Nullable>enable</Nullable>
77
</PropertyGroup>
88

99
<ItemGroup>
10-
<PackageReference Include="Microsoft.Extensions.Hosting" Version="6.0.0" />
11-
<PackageReference Include="Microsoft.DurableTask.Client.Grpc" Version="1.1.0" />
12-
<PackageReference Include="Microsoft.DurableTask.Worker.Grpc" Version="1.1.0" />
10+
<PackageReference Include="Microsoft.Extensions.Hosting" Version="8.0.1" />
11+
12+
<!-- Real projects would use package references -->
13+
<!--
14+
<PackageReference Include="Microsoft.DurableTask.Client.Grpc" Version="1.5.0" />
15+
<PackageReference Include="Microsoft.DurableTask.Worker.Grpc" Version="1.5.0" />
16+
-->
17+
</ItemGroup>
18+
19+
<ItemGroup>
20+
<!-- Using p2p references so we can show latest changes in samples. -->
21+
<ProjectReference Include="$(SrcRoot)Client/Grpc/Client.Grpc.csproj" />
22+
<ProjectReference Include="$(SrcRoot)Worker/Grpc/Worker.Grpc.csproj" />
1323
</ItemGroup>
1424

1525
</Project>

0 commit comments

Comments
 (0)