Code Room
System designHardsd-g270
Subject Collaborative editingLevel Senior–Staff~55 minCommon in Distributed systems interviewsIndustries Technology, Software development

Question

Design the sync engine for a CRDT-based collaborative document editor (think a rich-text note shared by a small team) that must work fully offline and converge once devices reconnect. Edits happen on phone, laptop, and web; two users can edit the same paragraph while both are offline for hours. There is no central 'lock' and no live connection required to keep editing. How do you guarantee all replicas converge to the same document without a coordinating server, and what does the server's role become?

What a strong answer looks like

Clarify scale and constraints first. Propose a clean component breakdown, then go deep on the hard parts — data model, bottlenecks, consistency, failure modes — and name the trade-offs you are making.

Narrate your design
Loading whiteboard…
Run or narrate your approach, then ask the coach.