mirror of
https://github.com/microsoft/agent-framework.git
synced 2026-06-16 21:04:09 +08:00
c79f886dc3
* dotnet: refresh Foundry sample guidance Carry forward the still-relevant sample guidance and Foundry-specific documentation fixes from the old stacked sample migration work, adapted to the current repo layout and policy. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * dotnet: rename Foundry sample env vars Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * dotnet: remove persistent provider sample Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * dotnet: drop SAMPLE_GUIDELINES.md from this PR Defer the guidelines doc and its cross-link to a follow-on PR to avoid broken-link failures in CI. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * dotnet: add DefaultAzureCredential warning to remaining samples Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * dotnet: address PR review feedback Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
c79f886dc3
ยท
2026-06-11 17:26:00 +00:00
History
Durable Workflow Samples
This directory contains samples demonstrating how to build durable workflows using the Microsoft Agent Framework.
Environment Setup
Prerequisites
- .NET 10 SDK or later
- Durable Task Scheduler running locally or in Azure
Running the Durable Task Scheduler Emulator
To run the emulator locally using Docker:
docker run -d -p 8080:8080 --name durabletask-emulator mcr.microsoft.com/durabletask/emulator:latest
Set the connection string environment variable to point to the local emulator:
# Linux/macOS
export DURABLE_TASK_SCHEDULER_CONNECTION_STRING="AccountEndpoint=http://localhost:8080"
# Windows (PowerShell)
$env:DURABLE_TASK_SCHEDULER_CONNECTION_STRING = "AccountEndpoint=http://localhost:8080"
Samples
Console Apps
| Sample | Description |
|---|---|
| 01_SequentialWorkflow | Basic sequential workflow with ordered executor steps |
| 02_ConcurrentWorkflow | Fan-out/fan-in concurrent workflow execution |
| 03_ConditionalEdges | Workflows with conditional routing between executors |
| 05_WorkflowEvents | Publishing and subscribing to workflow events |
| 06_WorkflowSharedState | Sharing state across workflow executors |
| 07_SubWorkflows | Nested sub-workflow composition |
| 08_WorkflowHITL | Human-in-the-loop workflow with approval gates |
Azure Functions
| Sample | Description |
|---|---|
| 01_SequentialWorkflow | Sequential workflow hosted in Azure Functions |
| 02_ConcurrentWorkflow | Concurrent workflow hosted in Azure Functions |
| 03_WorkflowHITL | Human-in-the-loop workflow hosted in Azure Functions |
| 04_WorkflowMcpTool | Workflow exposed as an MCP tool |