How microsoft/duroxide works
Duroxide is an embeddable Rust durable-execution runtime. A caller starts an orchestration through the client; the runtime dispatches orchestration work, replays recorded history, and runs registered activities, while a provider persists history and work. The runtime also exposes observability, and the repository includes SQLite storage plus reusable provider-conformance and stress-test utilities. README descriptions establish the user workflow; several internal connections rely on the source index, so unsampled implementation details are not inferred beyond those references.
Main entry points: providers/mod.rs Provider Contract · runtime/mod.rs Runtime · orchestration.rs Orchestration Dispatcher · core.rs Provider Stress Tests
Components 18
Workflow API
- Client API
src/client/mod.rs - Workflow Primitives
src/lib.rs - Async Combinators
src/combinators.rs
Execution Runtime
- Runtime
src/runtime/mod.rs - Handler Registry
src/runtime/registry.rs - Orchestration Dispatcher
src/runtime/dispatchers/orchestration.rs - Worker Dispatcher
src/runtime/dispatchers/worker.rs - Execution Engine
src/runtime/execution.rs - Replay Engine
src/runtime/replay_engine.rs - Runtime State
src/runtime/state_helpers.rs - Observability
src/runtime/observability.rs
Persistence
- Provider Contract
src/providers/mod.rs - SQLite Provider
src/providers/sqlite.rs - Instrumented Provider
src/providers/instrumented.rs
Provider Utilities
- Provider Validation
src/provider_validation - Validation Utilities
src/provider_validations.rs - Provider Stress Tests
src/provider_stress_test/core.rs
Other components
- Application
Connections 17
- Application → Client API: starts workflows
- Client API → Provider Contract: submits requests
src/client/mod.rs - Runtime → Orchestration Dispatcher: starts dispatchers
src/runtime/mod.rs - Runtime → Worker Dispatcher: starts dispatchers
src/runtime/mod.rs - Runtime → Handler Registry: uses registrations
src/runtime/mod.rs - Orchestration Dispatcher → Provider Contract: fetches work
src/runtime/dispatchers/orchestration.rs - Worker Dispatcher → Provider Contract: fetches work
src/runtime/dispatchers/worker.rs - Orchestration Dispatcher → Replay Engine: runs replay
- Execution Engine → Provider Contract: persists execution
- Replay Engine → Provider Contract: uses provider
src/runtime/replay_engine.rs - Runtime → Observability: records metrics
src/runtime/mod.rs - Instrumented Provider → Observability: records metrics
src/providers/instrumented.rs - SQLite Provider → Provider Contract: implements contract
src/providers/sqlite.rs - Validation Utilities → Provider Validation: re-exports tests
src/provider_validations.rs - Provider Validation → Provider Contract: checks behavior
src/provider_validation/mod.rs - Provider Stress Tests → Runtime: runs workloads
src/provider_stress_test/core.rs - Provider Stress Tests → Provider Contract: accepts providers
src/provider_stress_test/core.rs