Expand description
Data- and transport-agnostic interface to implement custom sync protocols, compatible with
p2panda-net or other peer-to-peer networking solutions.
Sync or “synchronisation” protocols (also known as “replication protocols”) are used to efficiently exchange data between peers.
Unlike gossip protocols, sync protocols are better solutions to “catch up on past state”. Peers can negotiate scope and access in a sync protocol for any type of data the remote peer currently knows about.
In addition to the generic definition of the SyncProtocol trait, p2panda-sync includes
optional implementations for efficient sync of append-only log-based data types. These optional
implementations may be activated via feature flags. Finally, p2panda-sync provides helpers to
encode wire messages in CBOR.
Enums§
- Messages which can be sent to the higher application layers (for further validation or persistance) and the underlying transport layer (for managing the sync session).
- Errors which can occur during sync sessions.
Traits§
- Traits to implement a custom sync protocol.
- Maps a
TopicQueryto the related data being sent over the wire during sync. - Identify the particular dataset a peer is interested in syncing.