I’ve come across CRDTs and I’m excited for their potential but I’m concerned that it doesn't really play nicely with databases that I know of. Whenever I have to update my database state I will still have to do some kind of locking beit pessimistic or optimistic before writing data. Unless there is a DB which accepts CRDTs, OTs or some kind of patchsets as part of its DSL and it handles the concurrency internally? Are there any such databases?
-
2[C-Set : a Commutative Replicated Data Type for Semantic Stores](http://ceur-ws.org/Vol-737/paper9.pdf) – Gilbert Le Blanc Aug 11 '21 at 13:29
1 Answers
There are several I know about. Starting from pretty solid ones:
- RiakDB is probably the most popular one, used on many high-volume production systems.
- Redis Enterprise offers plugin for geo-replication for most of its types.
There are also less mature cases like AntidoteDB which offers great hopes but it's very development process is rather slow (at the moment).
Some distributed databases offer limited support for some of the CRDT types eg. RavenDB and Cassandra counter type.
Azure CosmosDB allows you to configure a multi-master replication where you can define your own "stored procedure" (in JavaScript), that will be responsible for handling conflicts that occurred during concurrent writes. This way you can write your own CRDTs.
There are also products designed for working as CRDTs on client devices. These are not databases in a strict sense, but rather frameworks that can be embedded into application itself. They have support for persistence but usually are designed to work on smaller volumes of data. These include Yjs, automerge and ditto.

- 7,463
- 19
- 36