cd ../lexicon
sys/docs/lexicon/sloppy-quorum.md
Lexicon Entry

Sloppy Quorum

A quorum-based consistency mechanism where read/write operations are satisfied by the first N reachable nodes in the preference list, rather than strictly the N nodes that own the data's partition range. It trades strict quorum consistency for availability during partition-tolerant writes, at the cost of requiring downstream reconciliation via read-repair or hinted handoff.

In strict quorum systems, a write must be acknowledged by W nodes out of the N replicas that are canonically responsible for a key’s partition range, as determined by the partitioning function (e.g., consistent hashing ring position). If fewer than W of those specific nodes are reachable, the write fails outright — this is the behavior Dynamo’s original paper terms a strict quorum. Sloppy quorum relaxes this constraint: the coordinator walks the preference list (the ordered list of nodes clockwise on the hash ring past the key’s position) and accepts acknowledgments from the first W healthy nodes it encounters, regardless of whether those nodes are the ‘natural’ owners of the key.

The mechanical consequence is that data can land on a node outside the canonical replica set entirely. This is why sloppy quorum is architecturally inseparable from Hinted Handoff — the off-partition node accepting the write stores a hint indicating the true intended owner, and background processes later transfer the data to its correct home once the partition heals. Without this handoff mechanism, sloppy quorum degrades into silent data placement drift, where reads against the ‘correct’ owner nodes simply miss data that was written elsewhere during an outage.

  • Read-side implications: Because writes may have landed on non-canonical nodes, reads must also tolerate sloppiness — a read quorum R may query nodes that don’t have the freshest write if the hint hasn’t propagated yet, producing stale reads that require version-vector or vector-clock reconciliation on the client or coordinator.
  • Quorum intersection failure: The core safety guarantee of quorum systems — that any R and W quorum must overlap in at least one node (R + W > N) — can be violated under sloppy quorum during simultaneous partitions, since the set of nodes participating in a given write is not fixed. This is the primary criticism leveled against sloppy quorum in systems like Riak and Cassandra when strict consistency is assumed by application authors.
  • Configurability: Systems typically expose this as a toggle (Cassandra’s DatacenterAwareRoundRobin plus consistency level tuning, or explicit strict-vs-sloppy flags in Riak) because the availability gain only matters under actual node failure or network partition; under normal operation sloppy and strict quorums behave identically.

The architectural trade-off is a direct instantiation of the CAP theorem’s partition-tolerance clause: sloppy quorum is what lets an AP-leaning system keep accepting writes when the ‘correct’ replica set is unreachable, deferring correctness to asynchronous anti-entropy. Engineers building on top of such stores must treat any read as potentially inconsistent until hinted handoff and read-repair cycles complete, and should not conflate ‘write acknowledged’ with ‘write durable on canonical replicas’ — a distinction that has caused production data-loss incidents when W acknowledgments were misread as a durability guarantee equivalent to strict quorum semantics.