MongoDB
maang.io System Design Series
MongoDB stores flexible documents (BSON) instead of rows, letting you embed related data and evolve schemas freely. Under the hood: the WiredTiger engine (B-tree + document-level MVCC), replica sets with an oplog and elections, sharding for horizontal scale, and tunable read/write concerns. It's the default document store you'll compare against relational and wide-column options.
This deep dive comes in four parts:
- Foundations & Core Concepts — the document model and embedding vs referencing.
- Internals — WiredTiger, replica sets/oplog/elections, and sharding, with worked numbers.
- Advanced Internals — indexes, the aggregation pipeline, and read/write concerns.
- Interview — Staff/Principal Q&A: shard-key choice, consistency, and document-vs-relational.