Data Storage and Consistency
Move from in-memory structures to database plans, transaction visibility, replication, cache freshness, and consensus.
Curriculum (14 steps)
Compare arrays, hash tables, trees, heaps, and graphs by the operations they make cheap and the memory accesses they require.
Follow a key through hashing, bucket selection, collision handling, equality checks, and the returned value.
Build an LRU Cache
practiceCombine a hash map and a doubly linked list to support constant-time cache lookup, promotion, insertion, and eviction.
Trace SQL through parsing, logical rewrites, cost-based planning, physical operators, indexes, and the buffer pool.
Follow a selective SQL lookup through planning, a B-tree index, heap visibility checks, and the result rows.
Follow SQL through parsing and planning into scans, joins, buffers, visibility checks, and result rows.
Read a PostgreSQL Query Plan
practiceUse EXPLAIN to predict scans and joins, then compare row estimates with execution observations on a safe SELECT query.
What Does a Quorum Commit Guarantee?
interviewsA distributed-systems prompt about majority replication, protocol safety, leader changes, and availability without a quorum.
Turn user requirements into a data flow, capacity model, and failure-aware architecture before drawing infrastructure boxes.
Follow a read request through routing, a cache lookup, a database miss path, and a cache-fill decision.
Visualize a client request, routing, cache hit or miss, database access, and the chosen freshness policy.
Understand why timeouts, retries, ordering, and consistency matter when remote machines can fail independently.
Follow a client command from the leader's log through replication, quorum commitment, state-machine application, and reply.
Run a Raft Failure Tabletop
practiceUse a three-node cluster to reason about elections, log replication, quorum loss, and which client outcomes remain uncertain.