A process restart should not erase the distinction between an action that never began and one that already committed. Test recovery at operation boundaries, especially after a write succeeds but before its result is recorded locally.
Restart recovery depends on durable state
Workflow restart testing deliberately terminates a worker or agent process while work is in progress. The goal is to establish which state survives, which operations resume, and how uncertain effects are reconciled.
In a proposed design, persist operation identity, current intent revision, step states, and authoritative result references outside process memory. On startup, a recovery worker inspects unfinished operations rather than replaying every request blindly.
Call connection recovery and business-workflow recovery are separate capabilities. A workflow may reconcile correctly even when the telephone session cannot resume. Define what the caller hears and how staff receive outstanding work under that limitation.
Inject a fictional post-commit restart
A booking service creates appointment A-71. Before the worker stores the result, the process terminates. After restart, the workflow sees an unfinished local operation. It must use supported idempotency or an authoritative lookup to establish whether A-71 exists before attempting another booking.
A different fixture terminates the process before the write begins. That operation may be eligible to resume, provided the caller’s intent and prerequisites remain valid. The same restart command exercises different business states depending on timing.
| Restart point | Recovery invariant |
|---|---|
| Before queue acceptance | No invented pending operation |
| After durable queueing | Work is discoverable after startup |
| After external commit, before local result | Reconcile without duplicate effect |
| During notification retry | Preserve notification identity |
| After caller correction | Superseded operation cannot revive |
Assert the final records, operation history, and unresolved queue. A clean startup log is not evidence that the workflow recovered correctly.
Recovery needs ownership and limits
Some external effects cannot be reconciled automatically. Mark them uncertain and route them to a named staff queue rather than retrying indefinitely. Preserve enough context to explain the original request and the possible effect.
Durable orchestration adds persistence, cleanup, and migration work. For a simple low-impact operation, a smaller ledger may suffice. The required depth depends on the consequence of duplicate or lost effects, not the visual complexity of the conversation.
This recovery plan is proposed. The voice platform case study describes relevant integration work. Pair it with partial-success handling and safe retries.
Process restart FAQ
Does restarting the worker cancel external work?
No. Remote operations may continue or may already have committed.
Should all unfinished jobs be replayed?
Only after checking their operation state, freshness, and duplicate-protection contract.
What proves recovery succeeded?
The authorised outcome is preserved or explicitly unresolved, with no duplicate effects and a clear owner for remaining work.