Collaborative Text Editing with Eg-walker: Better, Faster, Smaller

Fuente: arXiv
Guardado en:
Detalles Bibliográficos
Autores principales: Gentle, Joseph, Kleppmann, Martin
Formato: Preprint
Publicado: 2024
Materias:
Acceso en línea:
Etiquetas: Agregar Etiqueta
Sin Etiquetas, Sea el primero en etiquetar este registro!
_version_ 1866914954583474176
author Gentle, Joseph
Kleppmann, Martin
author_facet Gentle, Joseph
Kleppmann, Martin
contents Collaborative text editing algorithms allow several users to concurrently modify a text file, and automatically merge concurrent edits into a consistent state. Existing algorithms fall in two categories: Operational Transformation (OT) algorithms are slow to merge files that have diverged substantially due to offline editing; CRDTs are slow to load and consume a lot of memory. We introduce Eg-walker, a collaboration algorithm for text that avoids these weaknesses. Compared to existing CRDTs, it consumes an order of magnitude less memory in the steady state, and loading a document from disk is orders of magnitude faster. Compared to OT, merging long-running branches is orders of magnitude faster. In the worst case, the merging performance of Eg-walker is comparable with existing CRDT algorithms. Eg-walker can be used everywhere CRDTs are used, including peer-to-peer systems without a central server. By offering performance that is competitive with centralised algorithms, our result paves the way towards the widespread adoption of peer-to-peer collaboration software.
format Preprint
id arxiv_https___arxiv_org_abs_2409_14252
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Collaborative Text Editing with Eg-walker: Better, Faster, Smaller
Gentle, Joseph
Kleppmann, Martin
Distributed, Parallel, and Cluster Computing
Collaborative text editing algorithms allow several users to concurrently modify a text file, and automatically merge concurrent edits into a consistent state. Existing algorithms fall in two categories: Operational Transformation (OT) algorithms are slow to merge files that have diverged substantially due to offline editing; CRDTs are slow to load and consume a lot of memory. We introduce Eg-walker, a collaboration algorithm for text that avoids these weaknesses. Compared to existing CRDTs, it consumes an order of magnitude less memory in the steady state, and loading a document from disk is orders of magnitude faster. Compared to OT, merging long-running branches is orders of magnitude faster. In the worst case, the merging performance of Eg-walker is comparable with existing CRDT algorithms. Eg-walker can be used everywhere CRDTs are used, including peer-to-peer systems without a central server. By offering performance that is competitive with centralised algorithms, our result paves the way towards the widespread adoption of peer-to-peer collaboration software.
title Collaborative Text Editing with Eg-walker: Better, Faster, Smaller
topic Distributed, Parallel, and Cluster Computing
url https://arxiv.org/abs/2409.14252