6 releases (3 breaking)

0.4.0 Feb 5, 2019
0.3.2 Feb 5, 2019
0.3.1 Jan 7, 2019
0.2.0 Dec 24, 2018
0.1.0 Dec 23, 2018

#2489 in Parser implementations

LGPL-2.1-or-later OR MIT

2.5MB
2K SLoC

Replicated Object Notation (RON) for Rust

RON is a protocol for synchronizing Conflict-free Replicated Datatypes (CmRDT). The documentation is hosted on docs.rs.

Differences with the reference implementation:

  1. No support for UUID varieties yet.
  2. Only LWW and 2-Phase sets.
  3. Handshake protocol is missing.
  4. Emits close RON exclusively.

Usage

# Cargo.toml
[dependencies]
ron-crdt = "0.4.0"

License

This project is licensed under either of

at your option.


lib.rs:

This is documentation for the ron-crdt crate.

RON is the Replicated Object Notation, a distributed live data format by Victor Grishchenko.

RON is the language in which object states and mutations, as well as all other parts of the Swarm protocol, are expressed in Swarm. RON consists (solely!) of a series of UUIDs (128-bit numbers), but the order of UUIDs matter, and there are many different kinds of UUIDs, depending on the context.

UUIDs provide sufficient metadata to object and their mutations to allow the implementation of CRDTs in a network of peers.

RON features two different wire formats: text and binary. Both offer several ways of compression, adding to the complexity. We will handle compression later, but note here that efficient compression is what makes RON and Swarm practical. Compression reduces the metadata overhead.

One particular combination of four UUIDs makes up an operation (short: ops) with one UUID each for the type, object, event and value. Several operations make up the state or mutation of an object, we call this a frame.

Special kinds of RON ops are used for protocol handshakes and frame headers (metadata for frames). These operations have special meaning, and often omit some of the metadata that is usually included in an operation (for example, a handshake query does not have a timestamp).

Dependencies