A Simple Convergent Value
A last write wins register is a replicated value that always converges by a simple rule: the write with the highest timestamp wins. When replicas exchange their copies, each keeps the value whose timestamp is larger, breaking ties by node id. Every replica that has seen the same set of writes ends with the same value.
Why It Converges
The rule is commutative and associative: merging in any order gives the same result. This makes the register a conflict free replicated data type, so no coordination is needed at write time. Replicas can accept writes independently and still agree later.
The Cost
The simplicity hides a real loss.
- When two writes are concurrent, the one with the smaller timestamp is discarded with no record.
- A clock skew can let a logically newer write lose to an older one that happened to carry a higher timestamp.
So last write wins is right only when losing a concurrent update is acceptable, such as a cached profile field, and wrong when every update must survive, such as a shopping cart.
Key idea
A last write wins register converges by keeping the highest timestamp value, simple and coordination free but silently dropping the losing concurrent write.