distributed-systems
19 free lessons tagged distributed-systems across Programming, Computer Science, AI. Each one is a short sequence of focused steps with narration and a five-question quiz at the end — take them in any order, no signup required.
Distributed Tracing and the Art of Throwing Data Away
Tracing every request through every service produces the most useful telemetry you have and more of it than anyone can afford. This lesson covers how context propagation actually stitches a trace together, the head versus tail sampling decision and why it determines which incidents you can debug, and the collector pipeline where all of it is enforced.
The Failure Modes the Design Creates
Reconciliation buys robustness and charges for it in a specific currency: nothing is ever definitely finished, commands succeed without meaning anything worked, and manual fixes are silently undone. This lesson covers the failures that come from the model rather than from bugs, how to debug them, and when the whole thing is the wrong tool.
Scheduling and Resources: Requests Are Not Limits
Two numbers govern where a pod lands and how it behaves under pressure, and they do completely different jobs. Requests are used for placement and are a promise; limits are enforced at run time and are a ceiling. This lesson separates them, covers the asymmetry between CPU and memory enforcement, and explains what actually happens when a node runs out.
Pods, Services, and the Label That Joins Them
The object types look like an arbitrary vocabulary until you notice they are layers of controllers, each reconciling the one below. This lesson works up from the pod, explains why a Service can point at something whose address changes constantly, and shows that the whole system is joined by one mechanism: a label match.
Reconciliation: Declare the End State, Not the Steps
Kubernetes is often taught as a pile of object types. Underneath it is one idea repeated: store a description of the desired state, and run loops that continuously compare it to reality and act on the difference. This lesson builds that loop, explains why it is level-triggered rather than event-driven, and shows what the design buys and costs.
Model Checking: Exhaustive Search Instead of Proof
The third tradition supplies no invariants and writes no proofs. It builds the set of states a system can reach and checks the property against all of them, which is decidable when that set is finite. This lesson covers what it buys, the state explosion that limits it, and the techniques that made it usable anyway.
Count-Min, and Why Sketches Compose
The count-min sketch estimates how often an item occurred using a fixed grid of counters, and it never underestimates. This lesson builds it, states the error bound that makes it usable, shows where it is useless, and ends on the property shared by all three structures that explains why they run distributed systems.
Training on Data You Are Not Allowed to See
The federated setting: why hospitals, phones, and banks cannot pool their data, what changes when the training loop crosses a network, and the FedAvg algorithm that made the idea practical.
Database Sharding and Replication
Go beyond a single database: learn how read replicas offload query load, how range and hash sharding partition data, why consistent hashing makes rebalancing tractable, and how to pick a shard key that avoids the celebrity problem and cross-shard pain.
Scaling and Load Balancing
Master the mechanics of scaling distributed systems: when to scale up versus out, why statelessness is the prerequisite for horizontal scale, how L4 and L7 load balancers differ, which balancing algorithm fits which workload, and how to avoid turning your load balancer into the next single point of failure.
Queues, Async, and Microservices
Learn how message queues and pub/sub decouple services, why at-least-once delivery demands idempotent consumers, how backpressure and dead-letter queues protect the system, and when microservices are worth the complexity — with a sequenceDiagram of async order processing.
Caching Strategies
Understand where caches live, how cache-aside, read-through, write-through, and write-back differ, how to choose eviction policies, and how to prevent cache stampedes — with hit ratio math and a concrete cache-aside code snippet.
Replication and Partitioning
How do you scale a database beyond one machine while keeping it reliable? This lesson covers every major replication topology, the quorum math behind leaderless systems, and partitioning strategies from range keys to consistent hashing — including how to avoid hot partitions and handle rebalancing.
Failure and Time in Distributed Systems
Distributed systems break in ways single machines don't: nodes crash silently, messages vanish, and clocks lie. Learn the standard failure taxonomy, why a global clock is physically impossible, and how Lamport and vector clocks let you reason about causality without one.
Consensus: Raft and Paxos
Consensus is the hardest fundamental problem in distributed systems — and the one everything else depends on. Understand why FLP makes it theoretically impossible in async systems, how quorums work, and exactly how Raft solves leader election, log replication, and commitment safely.
CAP and Consistency Models
CAP is the most misquoted theorem in distributed systems. Get the precise statement, learn why PACELC is more useful in practice, and master the consistency spectrum from linearizability down to eventual consistency — with concrete trade-offs for each level.
The CAP Theorem
Why every distributed system has to give up something when the network splits. CAP, the trade-offs in real databases, and the PACELC extension that's usually more useful in practice.
Load Balancing
How load balancers spread traffic across servers, what L4 and L7 actually mean, the routing algorithms in real use, and the failure modes you need to design around.
Apache Kafka: Distributed Event Streaming for Data-Intensive Applications
Dive into Apache Kafka, a powerful distributed streaming platform designed for high-throughput, fault-tolerant data pipelines. Understand its core components, architecture, and how it enables real-time data processing for modern applications.

