Interactive course · 4 lessons · ~1 hour

Consensus Algorithms

How do nodes agree over an unreliable network? Deep dive into the Two Generals' problem, Raft, leader election, and Byzantine fault tolerance.

01

The Consensus Problem

Why reaching agreement over an unreliable network is mathematically impossible (FLP Impossibility), and why we settle for "probabilistic" consensus.

Theory Live Interactive
02

Leader Election

How systems like ZooKeeper and etcd avoid split-brain by electing a single coordinator using leases, heartbeats, and randomized timeouts.

Live Interactive
03

The Raft Algorithm

Deep dive into Term numbers, uncommitted logs, and the commit index. Play as the leader trying to get a log entry committed to a majority of followers.

Core Algorithm Live Interactive
04

Byzantine Faults

Moving beyond crash-faults to Byzantine faults (malicious actors). Practical Byzantine Fault Tolerance (PBFT) and why blockchains are incredibly slow.

Live Interactive