Saga pattern
medium 30 minA saga is a chain of local transactions, one per service, with an undo step for each.
What each level should show
The same question is judged differently for mid, senior and staff.
Mid
Must show
- Defines saga and compensation
- Reverse order
- Both approaches with one trade-off each
Will be probed on
- Idempotency
- What a pending order is
Stands out
Names the undo of every step without being asked.
Senior
Must show
- Durable state and recovery
- Unknown outcomes after a timeout
- Outbox
Will be probed on
- Missing isolation
- Where the pivot is
Stands out
Reorders the steps to make undo cheaper.
Staff
Must show
- Questions the service boundary first
- Plans for stuck sagas and the people who fix them
- Versioning of running sagas
Will be probed on
- Visibility across teams
- Testing every crash point
Stands out
Writes one invariant and shows how each design keeps it.