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/

0d4ef9af8e4f0cf5c162b48ba24faea6?s=128

Martin Kleppmann

May 10, 2018
Tweet

Transcript

  1. None
  2. None
  3. None
  4. None
  5. None
  6. None
  7. None
  8. None
  9. None
  10. None
  11. None
  12. None
  13. None
  14. None
  15. None
  16. None
  17. None
  18. None
  19. None
  20. None
  21. None
  22. None
  23. None
  24. None
  25. None
  26. None
  27. None
  28. None
  29. None
  30. None
  31. None
  32. None
  33. None
  34. None
  35. None
  36. None
  37. None
  38. None
  39. None
  40. None
  41. None
  42. None
  43. None
  44. None
  45. None
  46. None
  47. 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.
  48. None
  49. None
  50. None
  51. 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.
  52. None
  53. Pixelpusher, a collaborative pixel art editor: https://github.com/automerge/pixelpusher Created by Javier

    Valencia, Jeff Peterson, Peter van Hardenberg, and Jim Pick.
  54. None
  55. None
  56. 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.
  57. Hypermerge, a peer-to-peer network layer: https://github.com/automerge/hypermerge Created by Jim Pick,

    Jeff Peterson, and Peter van Hardenberg.
  58. None
  59. None
  60. None
  61. None
  62. None
  63. None
  64. None
  65. None
  66. None
  67. None
  68. None
  69. None
  70. None
  71. None
  72. None
  73. None
  74. None
  75. None
  76. None
  77. None
  78. None
  79. None
  80. None
  81. None
  82. None
  83. None
  84. None
  85. None
  86. None
  87. None
  88. None
  89. None
  90. None
  91. None
  92. None
  93. None
  94. None
  95. None
  96. None
  97. None
  98. None
  99. None
  100. 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/
  101. None