Problem statement
Design the fan-out and delivery pipeline for a group-chat feature (think a popular team-messaging or community app) where a single message posted to a large group must reach every member, on every device, in the right order, quickly.
Operating context. Groups range from 2 to 10,000 members. Most groups are small, but the long tail of huge groups drives the pain: a burst in one 10k-member group is a single inbound write that amplifies into up to 10,000 delivery events. Members connect from phones, web, and desktop — a single user may hold 3+ live connections plus offline devices that reconnect hours later. Peak inbound is 50,000 messages/sec across all groups; steady state is ~8,000 messages/sec. Fan-out amplification pushes peak downstream delivery to ~2,000,000 events/sec. Delivery latency budget for online members is p99 < 2 s from send-accept to on-device receipt.
Out of scope. Message content moderation, end-to-end encryption key exchange, media transcoding/blob storage, push-notification vendor integration (assume a notifier service exists), presence/typing indicators, search indexing, and how the group-membership roster is authored (assume a members-of-group lookup already exists — but do reason about members joining or leaving mid-fan-out). Assume a separate team owns each.
What to produce. A high-level architecture covering: the send path (accept, sequence, persist), the fan-out strategy for large groups (write-fan-out vs. read-fan-out, and where you draw the line by group size), how a total order is assigned within a group, the per-member cursor / read-position model that lets each device track what it has seen, the catch-up sync path when a device reconnects after being offline, and how you apply backpressure when a slow or huge group threatens to overwhelm delivery. Sketch the components and the request/event flow; we will probe specifics in checkpoints.
Requirements
This assessment is a Premium feature.
The statement above is free to read. The functional and non-functional requirements, and the graded canvas that scores your design against them, come with Premium.
Topics
- System Design HLD
- Scaling Fanout
- Realtime Websocket
- Infra Queue
- Reliability Idempotency