2 ms·
> How do people deal with "eventual consistency"? In my head once a transaction is done, it's everywhere and everyone has access to it. Different strokes for d
by Florin_Andrei 10y ago
> How do people deal with "eventual consistency"? In my head once a transaction is done, it's everywhere and everyone has access to it.
Different strokes for different folks.
Synchronous replication: the whole cluster is a single unit. COMMIT only returns when it's been truly committed to all nodes. OTOH, it's slow, and may or may not tolerate partitions.
Asynchronous replication: COMMIT returns when it's gone into the current node. It is then the cluster's job to propagate it to the rest. This is a lot faster, and can deal with network partitions. OTOH there is usually a state lag between distant nodes.
Different applications may need either sync or async, depending on requirements.