Skip to main content

Module buffer

Module buffer 

Source
Expand description

Delta buffer for grouping and batching deltas Implements Algorithm 1 from the δ-CRDT paper (convergence mode)

§Algorithm 1: δ-CRDT Anti-Entropy (Convergence Mode)

The algorithm maintains:

  • A local state X
  • A delta buffer D
  • Sequence numbers for causal ordering

On local mutation m: d = mδ(X) // compute delta X = X ⊔ d // apply to state D = D ⊔ d // buffer delta

On send to peer j: send D[acked[j]..] to j

On receive delta d from peer i: X = X ⊔ d // apply (idempotent!) ack to i

Structs§

AckTracker
Tracks acknowledgments from peers for garbage collection
DeltaBuffer
Buffer for outgoing deltas with grouping support
DeltaReplica
A delta-CRDT replica implementing Algorithm 1
TaggedDelta
A delta tagged with sequence information for causal ordering

Type Aliases§

ReplicaId
Replica identifier
SeqNo
Sequence number for delta intervals