Hacker News new | ask | show | jobs
by juretriglav 3139 days ago
So glad to see that they've implemented this algorithm in JS! https://github.com/atom/teletype-crdt

I've tried implementing a very similar algorithm (one could say it's the same approach) in the beginning of this year, but had one remaining issue with concurrent overlapping deletions that I couldn't figure out (and the paper I was basing the algorithm on didn't account for it: http://www.sciencedirect.com/science/article/pii/S1474034616...): https://github.com/jure/rgass

Weihai Yu's implementation does account for it, however: https://dl.acm.org/citation.cfm?doid=2660398.2660401 , but his implementation is in Lisp, and I've never had the stamina to work through it for that one edge case.

Kudos to the team at GitHub, I'll be studying this implementation closely.

1 comments

I found this blog post on this subject very approachable: http://digitalfreepen.com/2017/10/06/simple-real-time-collab...
That's a nice blogpost! It does describe char-based CRDTs nicely, but the RGASS/teletype-crdt algorithms are string-based, which brings a lot of headaches, as you can have insertions that split existing nodes, etc.
Would love to learn how the two approaches differ from each other. The string-based one sounds more space efficient.