Side Read: What "Multi-Master, Globally Replicated" Actually Means
Part 1 — "multi-master" undersells it. Cassandra is masterless.
| Write model | Who may accept a write for a key | Losing that node / region means |
|---|---|---|
| Single-master (MySQL, Postgres primary) | Exactly one node — the primary | Promote a replica: writes down meanwhile, split-brain risk if the old primary isn't really dead |
| Multi-master | A small, designated set of leaders | Survivors keep writing but must reconcile, and you still track which leaders are alive |
| Cassandra — masterless | Any of the N replicas holding the key — peers, no leader, nothing to elect | Nothing to promote. The set of legal writers shrinks; it never has to be re-chosen |
| Where a write may enter | Any node. The partition key hashes onto the token ring, which names N replicas. The node your driver reaches acts as coordinator and forwards to those N — no leader consulted. |
|---|---|
| Where a write ends up | All N replicas. The coordinator returns once the consistency level's acks arrive — 2 of 3 for LOCAL_QUORUM; the rest apply in the background. |
So "every replica accepts writes" is about permission, not coordination: there is no primary anywhere, cluster-wide or per token range.
Part 2 — "globally replicated" is something you declare, per keyspace. Nothing is global by default.
A keyspace is Cassandra's top-level container — roughly a SQL "database" of tables; a cluster holds many. Replication is set per keyspace, as a list of regions with a copy count each:
CQL
CREATE KEYSPACE viewing_history WITH replication = {
'class' : 'NetworkTopologyStrategy',
'us-east-1' : 3,
'us-west-2' : 3,
'eu-west-1' : 3
};That's 3 copies in each of three regions — nine copies of every row, each region holding a complete copy, not a shard or cache. A region not in the map holds nothing, so keyspaces in one cluster routinely choose differently:
| What the keyspace declares | What that gets you |
|---|---|
{ us-east-1: 3, us-west-2: 3, eu-west-1: 3 } | Any region can serve — and accept writes for — any member. The precondition for the Regional failover part’s region evacuation. |
{ us-east-1: 3 } | Ordinary single-region keyspace: cheap, fast, invisible from Europe. Evacuate us-east-1 and it's gone from the serving path. |
{ us-east-1: 3, eu-west-1: 2 } | Counts are per region too — a secondary region can hold a thinner copy (analytics, read-mostly). |
So "globally replicated" really applies to the keyspaces a failover must preserve — viewing history, bookmarks, My List and friends. Region-scoped data usually skips the cross-region cost.
Two separate knobs: the replication map decides where the copies live; the consistency level on each query decides how many you wait for.
Putting them together — the write path.
- A write lands in
us-east-1. The coordinator sends it to the 3 local replicas and, in parallel, toward the other two regions. - It's acked at
LOCAL_QUORUMonce 2 of 3 us-east-1 replicas confirm. No cross-ocean round trip is ever in the request path. - Remote regions apply it when it arrives — milliseconds to seconds, longer if a link is degraded. Nobody waits on them.
The result: strong consistency within a region (R + W > RF, counting local replicas only), eventual consistency across regions, local-latency writes, and a full copy everywhere.
This is why the Regional failover part’s failover is a traffic-steering operation, not a database one. A single-master store would need a promotion — a write outage plus split-brain risk. With Cassandra the surviving regions were already accepting writes for that member; you just stop sending requests to one region.
The bill: conflicts resolve by last-write-wins on a per-cell timestamp. Two regions write the same field, one silently wins, and the application is never told. That pushes constraints upward:
| What you give up | What every service above must do |
|---|---|
| Transactions across rows | Model so a single row update is the whole operation |
| Read-modify-write safety | Blind, idempotent writes — set a value, never increment one you just read |
| Read-your-writes across regions | Tolerate a My List update briefly not showing from another region |
| Any conflict signal | Make last-write-wins semantically acceptable — or append rows and resolve at read time |