Why architecture matters here

Workflows fail on non-durability (crash loses state), unbounded retries, and version breakage on deploy. Architecture matters because engines handle these for you if used correctly.

Advertisement

The architecture: every piece explained

The top strip is the model. Workflow definition in code or DSL. State machine is the runtime. Persistence makes it durable. Retries + backoff handle transient failures.

The middle row is control. Timers + timeouts for time-based steps. Signals for external input. Compensation undoes on failure. Versioning handles evolution.

The lower rows are ops. Observability per-step trace. Testing replay tests. Ops covers Temporal / Cadence + drills.

Workflow orchestration — state machine + persistence + retries + durabilitylong-running agent workflows that survive restartsWorkflow definitioncode / DSLState machinesteps + transitionsPersistencedurable logRetries + backoffsafe attemptsTimers + timeoutstime-basedSignalsexternal inputCompensationundo on failureVersioningworkflow evolutionObservabilitystep traceTestingreplay testsOps — Temporal / Cadence / Camunda + drillswaitsignalcompensateevolvetracereplayreplayoperateoperate
Workflow orchestration pipeline for agents.
Advertisement

End-to-end flow

End-to-end: order workflow starts. Books inventory. Charges card. Ships. If ship fails, compensation reverses charge + release inventory. Server crashes mid-workflow; engine replays from persisted state on restart. Weeks later, code changes; version compatibility ensures running workflows finish under old logic while new ones use new.