Code Room
System designHard
Question
Design the comment + reply system for a social network where a user must always see their own newly posted reply immediately, and must never see a reply to a comment before seeing the comment it replies to. Scale: 500M DAU, reads 100x writes, comments served from geo-distributed read replicas with replication lag up to several seconds. Strong global consistency is too expensive. Which consistency model do you pick, and how do you enforce it end to end?
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.
Learn the concepts
Loading whiteboard…
Run or narrate your approach, then ask the coach.