IT lexicon Database Conflict resolution (DB)

Conflict resolution (DB)

Database På svenska → Updated: 2026-05-29

How a distributed database handles the same data being changed in different places at once and diverging. The strategies range from simple "last write wins" to keeping all versions and letting the application (or a CRDT) merge them.

Strategies: Last-Write-Wins (LWW) — pick the version with the highest timestamp (simple but can silently lose data, and requires synced clocks); keep siblings — store all competing versions (Riak) and let the client/app resolve them on the next read; application-specific merge (e.g. merge two shopping carts by union); CRDTs — data types that mathematically guarantee convergence without conflict. Detecting that a conflict happened requires version tracking (vector clocks). This is the price you pay for multi-leader/leaderless availability. The choice depends entirely on the data type and how bad it is to lose an update. Related to CRDT and vector clock.

← Back to the lexicon