Expand description
CRDT (Conflict-free Replicated Data Types)
Pure data structures for eventually consistent distributed state. CRDTs provide automatic conflict resolution - any two replicas can be merged to produce the same result regardless of order.
This crate is WASM-safe: NO IO, NO SystemTime, NO network dependencies.
The Synced<T> wrapper lives in logicaffeine_system (requires tokio/libp2p).
Re-exports§
pub use causal::Dot;pub use causal::DotContext;pub use causal::VClock;pub use sequence::RGA;pub use sequence::YATA;
Modules§
- causal
- Causal infrastructure for delta-state CRDTs.
- sequence
- Sequence CRDTs for collaborative lists and text.
Structs§
- AddWins
- Add-wins bias: concurrent add beats remove.
- Delta
Buffer - A ring buffer that stores recent deltas along with their versions.
- GCounter
- A grow-only counter that supports distributed increment operations.
- LWWRegister
- A register that resolves conflicts using “last write wins” semantics.
- MVRegister
- A register that keeps all concurrent values.
- ORMap
- An observed-remove map with nested CRDT values.
- ORSet
- An observed-remove set with configurable bias.
- PNCounter
- A counter that can be incremented and decremented.
- Remove
Wins - Remove-wins bias: concurrent remove beats add.
Traits§
- Delta
Crdt - A CRDT that supports delta-state synchronization.
- Merge
- A type that can be merged with another instance of itself.
- SetBias
- Resolution strategy for concurrent add/remove conflicts.
Functions§
- generate_
replica_ id - Generate a unique replica identifier.
Type Aliases§
- Replica
Id - Unique identifier for a replica in a distributed CRDT.