Expand description
Minimal sync contracts and local implementations.
Structs§
- File
Replication Log - File-backed append-only replication log for local runtime sync.
- File
Sync Checkpoint Store - File-backed checkpoint store (line-based
peer=sequence,hash). - File
Sync Outbox - Crash-consistent incremental file-backed synchronization outbox.
- Follower
Sync Client - Pushes leader events to a follower over transport.
- Heartbeat
Message - Transport-neutral heartbeat message.
- Http
Sync Transport - Bounded blocking HTTP client for leader-to-follower sync batches.
- InMemory
Replication Log - In-memory replication log for local sync scenarios.
- InMemory
Sync Checkpoint Store - In-memory checkpoint store for tests/local runtime.
- InMemory
Sync Outbox - Process-local synchronization outbox.
- Peer
Info - Peer metadata used by sync orchestration.
- Replication
Snapshot - Integrity-protected portable image of a replication log.
- Replication
Snapshot Record - Sequence-addressed event stored in a replication snapshot.
- Sync
Envelope V1 - Versioned sync envelope carrying the complete distributed source identity.
- Sync
Message - Mensagem de replicação enviada do líder para o seguidor.
- Sync
Peer Address - Parsed and normalized address of a synchronization peer.
- Sync
Push Metrics - Basic sync push metrics for local observability.
- Sync
Receive Ack - Ack returned by
/v1/sync/events. - Sync
Receiver State - In-memory receiver state for follower sync endpoint.
- Sync
Retry Policy - Retry and queue limits for follower push.
Enums§
- Node
Role - Node role used by leader election and write routing.
- Sync
Error - Sync-local typed errors.
- Sync
Peer Scheme - HTTP scheme supported by the built-in synchronization transport.
- Sync
Status - Coarse sync health and progress status.
Constants§
- REPLICATION_
LOG_ FORMAT_ V1 - Stable on-disk format marker for hash-chained replication logs.
- SYNC_
CHECKPOINT_ FORMAT_ V1 - Stable on-disk format marker for peer checkpoints.
- SYNC_
OUTBOX_ FORMAT_ V2 - Stable on-disk format marker for incremental durable sync outboxes. Stable on-disk format marker for incremental durable sync outboxes.
- SYNC_
SNAPSHOT_ FORMAT_ V1 - Stable format version for portable replication snapshots.
- SYNC_
WIRE_ SCHEMA_ V1 - Schema identifier for the first identity-aware sync wire envelope.
Traits§
- Leader
Election - Leader election contract.
- Replication
Log - Replication log contract.
- Sync
Checkpoint Store - Sync checkpoint storage contract by peer id.
- Sync
Outbox - Ordered bounded queue that retains replication batches until acknowledgement.
- Sync
Transport - Sync transport contract.
Functions§
- compute_
events_ hash - Computes the SHA-256 hash of events payload deterministically including size prefixes and batch metadata.
- decode_
sync_ envelope - Decodes the identity-aware v1 JSON envelope.
- decode_
sync_ message - Decodes a versioned v1 envelope and returns its replication message.
- discover_
dns_ sync_ peers - Resolves DNS peer seeds and returns normalized, de-duplicated addresses.
- encode_
sync_ envelope_ v1 - Encodes an identity-aware v1 envelope as JSON.
Type Aliases§
- Sync
Result - Sync-local result type.