flowdotnet.Core
0.1.5
dotnet add package flowdotnet.Core --version 0.1.5
NuGet\Install-Package flowdotnet.Core -Version 0.1.5
<PackageReference Include="flowdotnet.Core" Version="0.1.5" />
<PackageVersion Include="flowdotnet.Core" Version="0.1.5" />
<PackageReference Include="flowdotnet.Core" />
paket add flowdotnet.Core --version 0.1.5
#r "nuget: flowdotnet.Core, 0.1.5"
#:package flowdotnet.Core@0.1.5
#addin nuget:?package=flowdotnet.Core&version=0.1.5
#tool nuget:?package=flowdotnet.Core&version=0.1.5
dotflow
A .NET 10 workflow engine for building event-driven pipelines. Workflows are composed of phases wired together by events — no explicit dependency declarations, no DAG configuration. Phases start when their trigger fires.
Core concepts
Workflow
└── Phase[] triggered immediately or on a named event
└── TaskSlot a single task, or a concurrent group (Task.WhenAll)
└── DotflowTask your code
Immediate phases all start concurrently at trigger time. Event-triggered phases start when a matching event is published from any task during the run. The event graph is the dependency graph.
Getting started
Define tasks by subclassing DotflowTask:
public class ValidateOrderTask : DotflowTask
{
public override async Task ExecuteAsync(ITaskContext context, CancellationToken ct)
{
var orderId = context.Input["orderId"]?.ToString();
// do work...
context.SetOutput("customerId", "CUST-99");
await context.PublishEventAsync(new OrderValidatedEvent { OrderId = orderId }, ct);
}
}
Register workflows in DI:
services.UseInMemoryStore(); // or UsePostgreSQLStore(connectionString)
services.AddTransient<ValidateOrderTask>();
services.AddTransient<ChargeCardTask>();
services.AddTransient<SendReceiptTask>();
services.AddTransient<ShipOrderTask>();
services.AddDotflow(dotflow => dotflow
.ConfigureResiliency(r => r
.WithRetry(3, RetryStrategy.ExponentialBackoff, TimeSpan.FromMilliseconds(200)))
.AddWorkflow("order-processing", wf => wf
.WithName("Order Processing")
.AddPhase("validation", phase => phase
.TriggeredImmediately()
.AddTask<ValidateOrderTask>())
.AddPhase("payment", phase => phase
.TriggeredOn<OrderValidatedEvent>()
.AddTask<ChargeCardTask>()
.AddTask<SendReceiptTask>())
.AddPhase("fulfillment", phase => phase
.TriggeredOn<PaymentProcessedEvent>()
.AddTask<ShipOrderTask>())));
Trigger a run:
var engine = services.GetRequiredService<IWorkflowEngine>();
var run = await engine.TriggerAsync("order-processing", new Dictionary<string, object?>
{
["orderId"] = "ORD-12345"
});
Dashboard
Mount the built-in dashboard in any ASP.NET Core app:
app.UseDotflowDashboard("/dotflow");
The dashboard provides a real-time view of workflows, run history, phase/task breakdowns, and the ability to trigger or cancel runs. It uses HTMX polling — no WebSocket or SSE required.
Persistence
| Package | Use case |
|---|---|
dotflow.Persistence.InMemory |
Development and testing. Single-instance only. |
dotflow.Persistence.PostgreSQL |
Production. Dapper + Npgsql, run data stored as JSONB. |
Apply the PostgreSQL schema before first use:
await Migrator.MigrateAsync(connectionString);
Resiliency
Polly v8. Configure globally, per workflow, or per phase — most specific wins:
.ConfigureResiliency(r => r
.WithRetry(3, RetryStrategy.ExponentialBackoff)
.WithTimeout(TimeSpan.FromSeconds(30))
.WithCircuitBreaker(5, TimeSpan.FromSeconds(60)))
Extensions
dotflow.Extensions.MediatR— replaces the internal event bus with MediatR. UseINotificationHandler<T>for subscribers.dotflow.Extensions.Yaml— load workflow definitions from YAML configuration files.
Running the samples
# Console demo
dotnet run --project samples/dotflow.Sample.Basic
# Web host with dashboard at http://localhost:5000/dotflow
dotnet run --project samples/dotflow.Sample.WebApi
Requirements
- .NET 10
- PostgreSQL 14+ (if using the PostgreSQL persistence provider)
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.0)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.0)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.0)
- Microsoft.Extensions.Options (>= 10.0.0)
- Microsoft.Extensions.Resilience (>= 9.4.0)
- Ulid (>= 1.3.4)
NuGet packages (5)
Showing the top 5 NuGet packages that depend on flowdotnet.Core:
| Package | Downloads |
|---|---|
|
flowdotnet.Extensions.MediatR
MediatR event bus integration for dotflow. |
|
|
flowdotnet.Persistence.PostgreSQL
PostgreSQL persistence provider for dotflow. Uses Dapper and Npgsql with JSONB run storage. |
|
|
flowdotnet.Dashboard
ASP.NET Core dashboard middleware for dotflow — real-time workflow monitoring and management UI. |
|
|
flowdotnet.Extensions.Yaml
YAML configuration loader extension for dotflow. |
|
|
flowdotnet.Persistence.InMemory
In-memory persistence provider for dotflow. Suitable for development and testing. |
GitHub repositories
This package is not used by any popular GitHub repositories.