Module psync_sync

Module psync_sync 

Source
Expand description

PSync network protocol — wires PSyncNode + Ibf to Interest/Data exchange. PSync network protocol — wires PSyncNode + Ibf to Interest/Data exchange.

§Wire format

Sync Interest: /<group-prefix>/psync/<ibf-encoded>

The IBF is encoded as a series of <xor_sum:8><hash_sum:8><count:8> triples.

Sync Data: response carries the list of name hashes the responder has that the requester lacks, encoded as concatenated <hash:8> values.

§Protocol flow

  1. Periodically send a Sync Interest carrying the local IBF.
  2. When a peer receives it, subtract against local IBF, decode the difference.
  3. Reply with Data containing hashes the requester is missing.
  4. On receiving the Data, emit SyncUpdate for each missing hash.

Structs§

PSyncConfig
Configuration for a PSync group.

Functions§

join_psync_group
Join a PSync group.