I started revisiting distributed systems this week, beginning with the CAP theorem. The shorthand is familiar: during a network partition, a distributed system has to choose between consistency and availability. The useful part is less the slogan and more the question it forces: what should this system do when parts of it cannot talk?
For a workflow that records a sale, accepting two conflicting versions may be worse than briefly refusing a write. For a read-heavy catalogue, serving a slightly stale value may be a reasonable trade. The right answer depends on what the user believes the operation means and what recovery looks like.
CAP is specifically about a partition. It does not say every system must permanently choose consistency or availability, and it does not mean a system without a partition faces the same trade-off. Outside that case, latency and consistency still shape decisions; PACELC is a useful next lens for that.
My test for whether I understand a design is whether I can walk through a failure in a concrete system: which requests succeed, what data can be stale, how conflicts resolve, and how the system recovers. I tried applying that to an event pipeline and asynchronous replicas and found gaps. That is a better signal than being able to recite the acronym.
I’m working through this one design at a time. Next up: replication and the difference between eventual and linearizable reads.