What do you need when you're stranded? A raft.
An educational implementation of the Raft consensus algorithm in Go, built to explore the algorithm from the protocol messages up through leader election, log replication, and failure recovery.
proto
→ node skeleton (config/state/rpc plumbing, persist.go stubbed)
→ election (real logic + real persist)
→ replication (real logic + real persist)
→ client
→ failure/recovery + disasters
→ visualization
Development of stranded included conversations with Claude and ChatGPT to
discuss design tradeoffs (e.g. transport choice, idempotency strategy) and
work through Raft's protocol details. All code was written and is understood
by the author — these tools were used the way one might use a study partner,
not as a code generator.
We said there warn’t no home like a raft, after all. Other places do seem so cramped up and smothery, but a raft don’t. You feel mighty free and easy and comfortable on a raft.
—The Adventures of Huckleberry Finn by Mark Twain