Learn Labs
8. Transactions

8.8 Production failure catalog for this chapter

Production failure catalog
0 rows
SymptomUnderlying mechanism
Two increments, counter went up by oneLost update — read-modify-write race
User sees a new email but a zero unread countDirty read (or missing multi-object isolation)
Sale awarded to one buyer, invoice sent to anotherDirty write across two tables
$100 appears to vanish between two account readsRead skew under read-committed
A backup taken over 3 hours contains inconsistent dataBackup without snapshot isolation
Both doctors went off callWrite skew — snapshot isolation is not enough
Two bookings for the same room at the same timePhantom — nothing existed to lock
Two accounts registered with the same usernameWrite skew — fixable with a uniqueness constraint
Balance went negative despite a checkWrite skew on an aggregate — double-spending
User's work discarded on a transient errorORM doesn't retry aborted transactions
Retrying made the outage worseRetrying a contention/overload error instead of backing off
Email sent twiceSide effect outside the database on a retried transaction
Everything hangs; one query holds a whole-table lock2PL with no suitable index for a range lock
Latency p99 collapses under contention2PL blocking; one slow transaction stalls the system
Massive abort rate after enabling serializableSSI under high contention, or predicate lock escalation
Vacuum can't keep up; table bloats indefinitelyA long-running transaction pinning the MVCC horizon
Database refuses writes entirelyTransaction ID wraparound
Rows locked for 20 minutes, then foreverIn-doubt 2PC transaction; coordinator crashed or lost its log
Two systems permanently disagreeHeuristic decision on an in-doubt XA transaction
Committed transactions get aborted on recoveryCoordinator lost the most recent part of its log
A node shuts itself down for no visible reasonClock offset exceeded the configured maximum (Spanner/CockroachDB)
Cluster throughput collapses at 1,000 writes/sCross-shard transactions in a serial-execution system