Expand description
A general decentralized sync library supporting text and binary.
Vocabulary
Here are some terms I use throughout the codebase and documentation.
- resource - a piece of data (e.g. a file, online shared document). May also be used to denote the location of a resource.
- pier - another client on the network.
- help desire - how much a pier wants to help others in the network.
- conversation - a exchange of some related data (e.g.
MessageKind::LogCheck
). - [
den::Difference
] a modification to a resource. - UUID - a unique identifier for a unit (e.g. conversation,
Message
) - log - internal list to compensate for inconsistencies in message arrival time.
- storage - “versions” of the data stored by the implementor
- current storage - the current data. The resources stored here are the ones edited by the end-user.
- public storage - what the others think our current storage looks like. Separating these enables getting the difference between the storages. This returns what we need to send to the other piers, how to mutate the public storage to get the current storage.
Re-exports
pub use den;
pub use event::Event;
pub use event::IntoEvent;
pub use event::Kind as EventKind;
pub use log::Check as LogCheck;
pub use log::CheckAction as LogCheckAction;
Modules
- Events are a type of message which manipulate a resource.
- Mechanics for reading the current data from other piers after being offline for some time.
- Checking of hashes of
crate::resource
s. - Logs for
crate::Manager
. - Handling of getting and setting resources.
- Module for handling the sync between piers.
- Utilities for working with some datatypes used by agde.
Structs
- Describes the capabilities and properties of the client. Sent in the initial
Message
exchange. - The main manager of a client.
- A message to be communicated between clients.
- The appropriate pier selected from all piers
Capabilities::help_desire
. - A UUID.
Enums
- The action to follow after calling
Manager::apply_cancelled
. - The kinds of messages with their data. Part of a
Message
. - The recipient of a
Message
. - The action to perform after calling
Manager::apply_sync_reply
.
Constants
- The current version of this
agde
library.