Level 2: Data · L2.4 Transactions & isolation
Two-phase commit and why services avoid it
Explain 2PC and its blocking/availability cost.
11 min · Pro
What you take away
- Phase one asks every participant to durably promise it can commit; phase two tells them all what to do.
And 3 more inside the class, in Pro.
How the class is laid out
- The problem
- The simple version
- The protocol, and its cost
- What to do instead
- ACID
- Anomalies
- MVCC
- Concurrency control
- 2PC
- Check your understanding