System Design
18. Advanced Distributed ArchitectureAnimated
Distributed Transaction Processing
Transactions across many nodes.
The idea
Uses 2PC, sagas or deterministic ordering.
Watch it work
Press play, pause, or step through. Some animations have settings you can change.
- current message
- earlier
- failure or attack
Phase 1: the coordinator asks everyone if they can commit.
- step:
- 1/7
- from:
- Coordinator
- to:
- Participant A
1/7
Time runs downward. Solid arrows are requests, dashed arrows are replies.
Step by step
- 1Choose a protocol
- 2Coordinate participants
- 3Commit or compensate
- 4Recover from crashes
Where it is used
Cross-database operations.
Watch out for
Blocking and complexity.