Upgrade to Pro — share decks privately, control downloads, hide ads and more …

CRDTs: An UPDATE (or just a PUT)

Sam Elliott
October 30, 2013

CRDTs: An UPDATE (or just a PUT)

Riak 2.0's Data Types, presented at RICON West 2013, in SF.

A Few links for the interested:
- Dotted Version Vector Sets, a nice explanation: https://github.com/ricardobcl/Dotted-Version-Vectors#readme
- Our datatype repo: https://github.com/basho/riak_dt
- Comprehensive study of Convergent and Commutative Replicated Data Types (tech report): http://hal.upmc.fr/inria-00555588
- Optimised OR-Set (paper): http://arxiv.org/abs/1210.3368
- Dotted Version Vectors (paper): http://arxiv.org/abs/1011.5808
- Semilattices (wiki): https://en.wikipedia.org/wiki/Semilattice

Sam Elliott

October 30, 2013
Tweet

More Decks by Sam Elliott

Other Decks in Technology

Transcript

  1. ORSWOT: Merge Element In Both: Merge Dots Element In Only

    One: Drop when Dominated by Other’s VV Keep Otherwise
  2. Map: Merge Field In Both: Merge Dots Field In Only

    One: Drop when Dominated by Other’s VV Keep Otherwise
  3. C. Remove: The Incorrect Solution add(a) remove(a) {a,b} {a,b} {b}

    {a,b} {a,b} Sᵢ₊₁ Sᵢ Sᵢ₊₁ = op(Sᵢ) Sᵢ
  4. C. Remove: The Correct Solution add(a) remove(a) {a,b} {a,b} {a,b}

    {a,b} {a,b} Sᵢ₊₁ Sᵢ Sᵢ₊₁ = opᵤ(merge( Sᵢ , opᵣ() ) )
  5. Split Brain: The Incorrect Solution remove(a) {a,b} {b} {a,b} {b}

    Error Sᵢ₊₁ = op(Sᵢ) (eventually) {a,b} Sᵢ₊₁ Sᵢ
  6. Split Brain: The Correct Solution remove(a) {b} {a,b} {b} (eventually)

    {a,b} {a,b} Sᵢ₊₁ = opᵤ(merge( Sᵢ , opᵣ() ) ) Sᵢ₊₁ Sᵢ