Promptles
Architecture

CAP Theorem

advanced

Definition

A rule about systems that store data on many computers at once. It says you can have at most two of three things: everyone always sees the same data, the system always responds, and the system keeps working even when the computers can't talk to each other. You always have to give one up.

In the wild

Imagine two bank branches that briefly lose contact with each other. They have to choose: refuse all withdrawals until they reconnect (so balances stay perfectly accurate), or let people withdraw cash anyway (so the service stays available, but balances might be slightly out of sync for a few minutes). They can't have both.

More from Architecture