barrel_rep_alg (barrel_docdb v1.0.0)
View Sourcebarrel_rep_alg - Replication algorithm
Implements the core version-vector replication algorithm: one diff_versions round-trip per batch of changes, then a get_doc + put_version per missing document. Conflict handling lives entirely in the target's put_version (fast-forward, ignore, or record a conflict sibling), so the algorithm itself needs no ancestor negotiation.
Summary
Functions
Replicate a list of changes from source to target.
Replicate changes in batches with checkpoint callback
Types
-type att_info() :: #{name := binary(), content_type := binary(), length := non_neg_integer(), digest := binary(), chunked => boolean(), chunk_size => pos_integer(), chunk_count => pos_integer()}.
-type change() :: map().
-type db_name() :: binary().
-type docid() :: binary().
-type revid() :: binary().
-type seq() :: barrel_hlc:timestamp().
-type seq_string() :: binary().
-type view_name() :: binary().
Functions
Replicate a list of changes from source to target.
Replicate changes in batches with checkpoint callback