Click any tag below to further narrow down your results
Links
This article dives into the hidden failures that crop up when your database leaves the ideal “happy path.” It covers contention, slow queries, race conditions, stale reads, retries and live migrations, and shows how production realities can break simple transactional code.
- A slow query isn't just "slow" — threads sitting idle in transactions hold locks and connections until the pool fills up and unrelated requests start timing out.
- Client-side timeouts and retries can pile new connections onto a backlog while the original transaction still commits, causing duplicate orders or inconsistent stock.
- Concurrent "check stock" calls can each see available inventory and decrement it in parallel, leading to overselling.
- Replica lag and mixed old/new code during schema migrations can silently feed stale reads or trigger deadlocks in production.
This course covers core concepts of concurrency control—threads, locks, transactions, and crash recovery—in the first half, then shifts to distributed systems topics like network models, clocks, replication, consensus, and fault tolerance. It lists lecture topics, objectives, prerequisites, and recommended readings for a Part IB CST Michaelmas module led by Dr. Martin Kleppmann.
- Kleppmann's 16-lecture Part IB course splits evenly: 8 lectures on concurrency control, 8 on distributed systems.
- The concurrency half moves from basic threads/locks through bakery algorithm, semaphores, monitors, and message-passing (actors, CSP) to ACID transactions, 2PL, optimistic concurrency, and crash recovery.
- The distributed half covers network/failure models, physical and logical clocks, replication and consensus (Raft, FLP impossibility, 2PC, CAP), ending with case studies on CRDTs and Google Spanner's TrueTime.
- Core texts backing the course are Tanenbaum's Modern Operating Systems, Goetz's Java Concurrency in Practice, and Kleppmann's own Designing Data-Intensive Applications.