System Design Case Studies
Whole systems, end to end: a social feed, a chat service, a payment ledger, a video platform and a search engine, each carried from the ask through its numbers, its hard part and its failure to a design you can defend.
- Islands
- 5
- Lessons
- 25
- Exercises
- 145
- Island 1
The Social Feed
A home feed for a hundred million users: where a timeline lives, how it is ranked inside a latency budget, what the celebrity accounts do to the write path, and the whole design under a viral hour.
- Island 2
The Chat Service
Messaging for fifty million users: the long-lived connections and the servers that hold them, one order per conversation and delivery that survives a retry, presence and the offline device, and the whole design under a reconnect storm.
- Island 3
The Payments Ledger
Money that must always add up: an append-only double-entry ledger, transfers that survive any retry, reconciliation against providers that retry too, and the whole design under a provider outage.
- Island 4
The Video Platform
Uploads that become a dozen renditions, a backlog that must not eat the fleet, storage tiers priced by how often a video is watched, delivery that pays per byte, abuse that costs real money, and the whole design under a viral clip.
- Island 5
The Search Engine
Search over a billion documents: an index sharded by document with a query fanned out and merged, an indexing pipeline that keeps up with the web's changes, autocomplete inside a keystroke, and the whole design under a query that half the world types at once.