| Sure! In our documentation we go over some of the details here: https://docs.ditto.live/javascript/common/how-it-works/crdt I'm not sure if you know what CRDTs are but they're a family of data types that allow different actors in a distributed system to edit data concurrently even during network partitions. If enough data is shared, they will deterministically agree on the same value. They kind of give that "google docs" behavior if you're looking for an analogy. They're perfect for peer to peer and offline-first systems. However there is actually more to it, and a much more detailed write up is coming soon. Ditto is a distributed database, each peer has it's own database. The database is organized into collections and each collection is a Ditto Document (this does not work like most NoSQL document databases). Each property of the document is it's own CRDT, you as the user can pick which CRDT you'd like to use, our current catalog includes: * Registers (Causal Last Write Wins)
* Counters (sums of each writer's numeric values)
* Binary Attachments (same as a Register but you can put large arbitrary data like say video files, images, PDFs whatever)
* AddWinsMaps (coming soon) - This type allows for concurrent upserting and removing of values based on a key.
* ReplicatedGrowableArray - this is an array type that allows for concurrent insertions while preserving some semblance of order. It behaves rather closely to a collaborative text editor merge behavior. Our AddWinsMap and ReplicatedGrowableArray are more special than you might think. They can actually host nested CRDTs. Think of it like a folder within a folder in Google Drive that can hold synced documents nested within. I'd love to show you over perhaps a call! We tend to be perfectionist when it comes to documentation and have been so busy that we haven't fleshed it all out. Perhaps we might just open source our CRDT system. Email is in my profile, I love chatting and sharing about this stuff! |