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

Automerge: Making servers optional for real-time collaboration

Automerge: Making servers optional for real-time collaboration

Slides from a talk given at Craft Conference, Budapest, Hungary, 10 May 2018
http://martin.kleppmann.com/2018/05/10/craft-conf.html
and at J on the Beach, Málaga, Spain, 24 May 2018
https://jonthebeach.com/speakers/4/Martin+Kleppmann

Abstract:

Once upon a time, we used software that ran on our own computers, that worked offline, and that stored its data in files on the local disk. Then we decided to put it all in the cloud. We gained some great features: real-time collaboration, like in Google Docs, for example. But we also lost control of our own data, and became dependent on far-away servers to allow us to access the data that we created.

Automerge is part of an effort to get the best of both worlds. It is a JavaScript library for building real-time collaborative applications. However, apps built with Automerge also work offline, storing data locally, and synchronise their data with collaborators whenever a network is available. And although you can use it with servers, you don’t have to: synchronisation also works peer-to-peer, or via any network you choose.

In this talk we will explore how Automerge deals with different users independently modifying shared data in a collaborative application (hint: by merging the changes… automatically!), how it achieves consistency in highly distributed settings, and where it is heading in the future.

Resources:

Automerge: https://github.com/automerge/automerge
Trellis: https://github.com/automerge/trellis
Pixelpusher: https://github.com/automerge/pixelpusher
MPL (WebRTC layer): https://github.com/automerge/mpl
Hypermerge: https://github.com/automerge/hypermerge
Dat / Hypercore: https://datproject.org/
Proving CRDTs correct: https://doi.org/10.1145/3133933
JSON CRDT: http://arxiv.org/abs/1608.03960
My book: http://dataintensive.net/

Martin Kleppmann

May 10, 2018
Tweet

More Decks by Martin Kleppmann

Other Decks in Programming

Transcript

  1. For details, see our paper at https://doi.org/10.1145/3133933 Victor B. F.

    Gomes, Martin Kleppmann, Dominic P. Mulligan, and Alastair R. Beresford: Verifying Strong Eventual Consistency in Distributed Systems. PACMPL 1(OOPSLA), 2017.
  2. Trellis, a Trello clone based on Automerge: https://github.com/automerge/trellis Joint work

    with Orion Henry, Peter van Hardenberg, Roshan Choxi, and Adam Wiggins.
  3. MPL, a WebRTC network layer for Automerge: https://github.com/automerge/mpl Joint work

    with Orion Henry, Peter van Hardenberg, Roshan Choxi, and Adam Wiggins.
  4. Resources • Automerge: https://github.com/automerge/automerge • Trellis: https://github.com/automerge/trellis • Pixelpusher: https://github.com/automerge/pixelpusher

    • MPL (WebRTC layer): https://github.com/automerge/mpl • Hypermerge: https://github.com/automerge/hypermerge • Dat / Hypercore: https://datproject.org/ • Proving CRDTs correct: https://doi.org/10.1145/3133933 • JSON CRDT: http://arxiv.org/abs/1608.03960 • My book: http://dataintensive.net/