Dbos.Transact.Postgres 0.0.0-alpha.0.47

This is a prerelease version of Dbos.Transact.Postgres.
dotnet add package Dbos.Transact.Postgres --version 0.0.0-alpha.0.47
                    
NuGet\Install-Package Dbos.Transact.Postgres -Version 0.0.0-alpha.0.47
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Dbos.Transact.Postgres" Version="0.0.0-alpha.0.47" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Dbos.Transact.Postgres" Version="0.0.0-alpha.0.47" />
                    
Directory.Packages.props
<PackageReference Include="Dbos.Transact.Postgres" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Dbos.Transact.Postgres --version 0.0.0-alpha.0.47
                    
#r "nuget: Dbos.Transact.Postgres, 0.0.0-alpha.0.47"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Dbos.Transact.Postgres@0.0.0-alpha.0.47
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Dbos.Transact.Postgres&version=0.0.0-alpha.0.47&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Dbos.Transact.Postgres&version=0.0.0-alpha.0.47&prerelease
                    
Install as a Cake Tool

dbos-transact-csharp

A C#/.NET port of dbos-transact-java — a lightweight durable-workflow library built on top of a relational database.

Status: alpha (0.0.0-alpha.x) — published to NuGet for early testing. The API closely mirrors the Java reference implementation.

What DBOS Transact gives you

  • Durable workflows checkpointed to the database, with automatic resume-on-restart.
  • Durable queues with no external broker.
  • Scheduled execution — cron and long durable sleeps.
  • Workflow events and notifications with exactly-once delivery.
  • Async workflow handles with status polling and result retrieval.
  • Admin HTTP endpoints and conductor (WebSocket) protocol parity with the other DBOS runtimes.

Quick Start

Install

dotnet add package Dbos.Transact --version 0.0.0-alpha.0.43
dotnet add package Dbos.Transact.Postgres --version 0.0.0-alpha.0.43

Or use SQLite for a zero-dependency local setup:

dotnet add package Dbos.Transact --version 0.0.0-alpha.0.43
dotnet add package Dbos.Transact.Sqlite --version 0.0.0-alpha.0.43

Declare steps and a workflow

using Dbos.Transact.Workflow;

// Steps — durable, checkpointed on each call
public interface IMySteps
{
    [Step] Task<string> FetchDataAsync(string url);
    [Step] Task SaveResultAsync(string data);
}

public sealed class MySteps : IMySteps
{
    public async Task<string> FetchDataAsync(string url) { /* ... */ }
    public async Task SaveResultAsync(string data) { /* ... */ }
}

// Workflow — resumes from the last completed step after a crash
public interface IMyWorkflow
{
    Task RunAsync(string url);
}

public sealed class MyWorkflow(IMySteps steps) : IMyWorkflow
{
    [Workflow]
    public async Task RunAsync(string url)
    {
        var data = await steps.FetchDataAsync(url);
        await steps.SaveResultAsync(data);
    }
}

Register, launch, and run

using Dbos.Transact;
using Dbos.Transact.Sqlite;

await using var dbos = Dbos.Builder("my-app")
    .UseSqlite("Data Source=myapp.db")
    .Build();

var stepProxy = dbos.RegisterProxy<IMySteps>(new MySteps());
dbos.RegisterProxy<IMyWorkflow>(new MyWorkflow(stepProxy));

await dbos.LaunchAsync();

var handle = await dbos.StartWorkflowAsync<object?>(
    workflowName: nameof(MyWorkflow.RunAsync),
    className: typeof(MyWorkflow).FullName,
    instanceName: null,
    args: ["https://example.com"]);

await handle.GetResultAsync();

With Microsoft.Extensions.Hosting:

services.AddDbos("my-app", builder => builder.UsePostgres(connectionString));
services.AddDbosWorkflow<IMySteps, MySteps>();
services.AddDbosWorkflow<IMyWorkflow, MyWorkflow>();
// Or auto-register every [Workflow]/[Step]/[Scheduled]-bearing type in an assembly:
// services.AddDbosWorkflowsFromAssembly(typeof(Program).Assembly);

For a full walkthrough see docs/raw/csharp-programming-guide.md.

Packages

NuGet Role
Dbos.Transact Core — dialect-agnostic. [Workflow] / [Step] / [Scheduled] surface, executor, registries, portable serializer, migrations.
Dbos.Transact.Postgres Npgsql-backed Postgres dialect. LISTEN/NOTIFY, SKIP LOCKED, advisory locks.
Dbos.Transact.Sqlite Microsoft.Data.Sqlite-backed dialect. First-class production target for small single-host projects; Litestream is the documented backup path.
Dbos.Transact.Hosting Microsoft.Extensions.Hosting integration — services.AddDbos(…) + AddDbosWorkflow<TInterface, TImpl>().
Dbos.Transact.SemanticKernel Microsoft Semantic Kernel bridge. kernel.AddDbosPlugin(dbos, tools) checkpoints every [Step]+[KernelFunction] tool invocation; kernel.AddDurableChatCompletion(dbos) checkpoints every LLM turn. Together they let an agent loop replay end-to-end without re-spending tokens or re-firing tool side effects.
Dbos.Transact.Cli System.CommandLine-based CLI (migrate, reset, workflow).

Target framework

net8.0 (current LTS). Multi-targeting net10.0 can be added later if there is demand.

Documentation

Upstream references

License

MIT

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.0.0-alpha.0.47 70 5/5/2026
0.0.0-alpha.0.43 53 5/4/2026
0.0.0-alpha.0.42 54 5/4/2026
0.0.0-alpha.0.40 68 5/3/2026
0.0.0-alpha.0.35 55 5/2/2026