Research Library · Idea
CAP theorem
The CAP theorem says that a networked shared-data service cannot guarantee both consistency and availability when the network can lose messages. Eric Brewer conjectured it in an invited talk at PODC 2000, and Seth Gilbert and Nancy Lynch proved a formal version in "Brewer's Conjecture and the Feasibility of Consistent, Available, Partition-Tolerant Web Services" (SIGACT News 33(2), June 2002).1
The proof fixes the terms. Consistency is atomic (linearizable) consistency of a read/write object: operations behave as if each took effect at a single instant in a total order. Availability means every request received by a non-failing node eventually gets a response, with no time bound. Partition tolerance is modelled as the network losing arbitrarily many messages. Theorem 1 states that in the asynchronous network model no algorithm can guarantee availability and atomic consistency in all fair executions, including those that lose messages. The argument splits the nodes into two groups with all messages between them lost: a write completes in one group, a later read in the other cannot see it, and the algorithm must either answer wrongly or not answer. Corollary 1.1 adds that an algorithm that is available in all fair executions cannot even guarantee atomic consistency in executions where no message is lost, because it cannot tell a lost message from a delayed one. The impossibility persists in a partially synchronous model.1 The authors later placed it among the general impossibilities of safety plus liveness in an unreliable system.2
Brewer's 2012 article says the "2 of 3" slogan was always misleading: partitions are rare, the choice can be made per operation, and consistency and availability come in degrees. He recommends detecting a partition, entering an explicit partition mode that limits some operations, and recovering afterwards.3
Dynamo is a production example that chose availability, accepting stale reads and application-level reconciliation.4
Source · Brewer's Conjecture and the Feasibility of Consistent, Available, Partition-Tolerant Web Services (opens in a new tab) · Seth Gilbert and Nancy Lynch, ACM SIGACT News 33(2), June 2002
References
- Brewer's Conjecture and the Feasibility of Consistent, Available, Partition-Tolerant Web Services (opens in a new tab) · ACM SIGACT News 33(2) · June 1, 2002 ↩ ↩
- Perspectives on the CAP Theorem (opens in a new tab) · IEEE Computer 45(2) · February 1, 2012 ↩
- CAP Twelve Years Later: How the Rules Have Changed (opens in a new tab) · Eric Brewer, IEEE Computer; InfoQ reprint · May 30, 2012 ↩
- Dynamo: Amazon's Highly Available Key-value Store (opens in a new tab) · SOSP 2007 · October 14, 2007 ↩
Research articles
- Where the data lives, and what it gives away: a reader in data engineering from the relational model to differential privacy · Data science & statistics
See what connects to it on the map of ideas →

SecSIG