A timeout leaves an unknown outcome
What This Concept Is
A saga coordinates separately committed steps and the business actions needed when the workflow cannot finish as intended. A timeout describes the coordinator's knowledge; it does not prove that a participant failed to commit. Cancellation intent and confirmed cancellation are different states.
Why It Matters Here
The original three-service saga lab needs explicit handling of late and duplicated outcomes. Treating timeout as a negative result can release a reservation while a payment is still being charged, then incorrectly declare the workflow settled.
Concrete Example
Reservation and payment requests have been issued. The coordinator times out and enters cancelling with both outcomes unknown. There are no known compensations yet, but it cannot declare cancelled. Payment later reports success: refund is now due. After refund confirmation, reservation remains unknown, so the workflow still cannot close. A definitive reservation failure finally permits cancelled.
If both participants report success before cancellation, the synthetic workflow completes. A timeout arriving afterward is rejected: cancellation of a completed purchase belongs to another explicitly designed workflow. This is a domain choice, not a universal saga rule.
Common Confusion / Misconception
No pending compensation is not the same as no unresolved work. An unknown participant can still report success later. Recording a permanent failure without evidence hides that exposure. A saga also does not supply isolation between concurrent workflows automatically.
How To Use It
Separate definitive participant outcomes from cancellation intent. Draw the state transitions and mark which event establishes each fact. Give each operation a correlation identity and reconcile missing outcomes with its owner. Define escalation when an outcome remains unknown indefinitely; do not manufacture a result just to make the state machine terminate.
Check Yourself
Why can cancelling have no compensation due? What changes when a late payment success arrives? What business assumption makes a completed workflow different from an abandoned pending one?
Mini Drill or Application
Hand-trace timeout, payment success, refund confirmation and reservation failure. Reorder the definitive results and repeat them. Record which orderings complete and which require compensation before implementing the archive.
Read This Only If Stuck
Microservices Patterns — sagas. The saga pattern describes local transactions and compensation; the outcome protocol here is a bounded original exercise.