Mateo Sanabria, Nicolás Cardozo

Syncordian: A Byzantine Fault Tolerant CRDT without Interleaving anomalies

BEFORE WE START

This is not a finish project, we are actively working on it.  Feel free to point mistakes or inconsistencies, peer review is always appreciated 
  • What is a CRDT?
    • Interleaving Anomalies?
  • Byzantine Fault Tolerant?

Syncordian: A Byzantine Fault Tolerant CRDT without Interleaving anomalies

Les't remember some CS foundation

The CAP THEOREM

CAP: Any distributed data store can provide only two of the following three guarantees
  • Consistency
    Every read receives the most recent write or an error
  • Availability
    Every request receives a (non-error) response, without the guarantee that it contains the most recent write

  • Partition Tolerance

    The system continues to operate despite an arbitrary number of messages being dropped (or delayed) by the network between nodes

For example, in the context of internet-scale distribution requires data replication across multiple geographic locations with low latency and high availability

Strong Consistency:
  • Requires coordination for executing operations.
  • Challenges arise in the presence of network partitions or failures. 
Weak Consistency:
  • Allows temporary divergence among replicas.
  • Requires a mechanism for merging concurrent updates into a common state.

Eventual Consistency

Informally, eventual consistency means that replicas eventually reach the same final value if clients stop submitting updates:
Eventual Delivery: An update delivered at
some correct replica is eventually delivered to all correct replicas


Convergence: Correct replicas that have delivered the same updates eventually reach equivalent state
  • Some Eventual Consistency (EC) systems execute updates intermediately, only to later identify conflicts and roll back, resulting in resource wastage.
  • Resolving conflicts often necessitates a consensus among replicas to ensure consistent arbitration.
  • To address this, a stronger condition is needed to enhance efficiency and minimize resource wastage in EC systems.

Eventual Consistency

strong Eventual Consistency (SEC)

Strong Convergence: Correct replicas that have delivered the same updates have equivalent state
EventualConsitency \wedge StrongConvergence \\ \equiv SEC

Conflict-free Replicated Data Types (CRDT)

Is an abstract data type designed to be replicated at multiple nodes and exhibiting the following properties:
  • Any replica can be modified without coordinating with any other replicas.
  • When any two replicas have received the same set of updates.

Conflict-free Replicated Data Types (CRDT)

CRDTs rely on commutative operations to guarantee strong eventual consistency this avoids the need for synchronization, yielding high availability and low latency 

Availability + Partition Tolerance + SEC

The 'best' case of application for a complex crdt

peer to peer COLLABORATIVE   TExt editing

INTERLEAVING ANOMALIES

BYZANTINE FAULT

WHAT ABOUT SYNCORDIAN?

Context: peer to peer COLLABORATIVE text editing
  • P2P Network, all messages will eventually arrive. 
  • Multiple peers in the network.
  • Each pear has its document' copy.
  • Each honest peer can edit the document: Insert and Delete.

SYNCORDIAN

SYNCORDIAN: Document

A syncordian document is a list of line. A line of a document has:
  • (line_id) :: float -> allows to know the relative position of the line in the document.
  • status :: :tombstone | :aura | :settled
  • insertion_attempts :: integer -> Counter to keep track of the insertion attempts.
  • content :: String.t() -> The actual content of the line. 
  • siganture :: String.t() -> A hash signature use to prevent Byzantine faults

SYNCORDIAN: Peer

A peer syncordian peer is composed of :
  • A peer ID
  • A syncordian document
  • A vector clock
Board Time!

SYNCORDIAN

By Mateo Sanabria Ardila

SYNCORDIAN

Syncordian

  • 32