Tuesday, June 02, 2026

CRDTs, Automerge: Local-First Software; book: Designing Data-Intensive Applications

In the context of computer science and distributed systems, CRDTs (Conflict-free Replicated Data Types) are specialized data structures that allow multiple users or systems to update the same data independently and concurrently without a central coordinator. They are designed to automatically merge divergent copies back into a single consistent state, making them a foundation for local-first and real-time collaborative software

1. Conflict-free Replicated Data Types (Computing)
CRDTs ensure Strong Eventual Consistency (SEC). This means that while different users might see slightly different versions of data at the same moment, once all updates have been received, every copy is guaranteed to be identical without any manual conflict resolution. [1, 2, 3, 4]
Key Characteristics
  • Decentralized: No central server is required to decide the "correct" version; every node is a peer.
  • Offline Support: Users can make changes while disconnected; these are merged seamlessly upon reconnecting.
  • Mathematical Properties: To work, their merge operations must be commutative (order doesn't matter), associative (grouping doesn't matter), and idempotent (duplicate updates don't change the result). [1, 2, 3, 4, 5, 6]

podcast

SE Radio 716: Martin Kleppmann Local-First Software – Software Engineering Radio

References
Amazon.com: Designing Data-Intensive Applications, 2nd Edition: The Big Ideas Behind Reliable, Scalable, and Maintainable Systems (Audible Audio Edition): Martin Kleppmann, Chris Riccomini, Graham Mack, Ascent Audio: Books



No comments: