System Design Chat Application: Interview Talk Track

System Design Chat Application: Interview Talk Track

A system design chat application interview talk track is a classic mid/senior prompt: realtime delivery, fan-out, storage, and presence without boiling the ocean. Candidates commonly practice 1:1 messaging first, then group chat, typing indicators, and media as extensions. This guide is a structured script—from clarifying questions through APIs, data model, and tradeoffs—not a claim about any company’s confidential prompt.

Clarify before you draw

Ask and write assumptions:

Talk track:

“I’ll start with reliable 1:1 text chat with offline inbox, then extend to small groups. Media via object storage and CDN. Presence and typing as best-effort. I’ll assume TLS in transit and server-stored history unless you want E2E as a constraint.”

Invite correction early. Scope control is part of the grade.

APIs (keep boring)

Idempotency: clientMsgId prevents double-send on retries.

Capacity sketch (order of magnitude)

Pick round numbers and show method:

Talk track:

“Writes are substantial but fan-out and concurrent connections dominate complexity. I’ll separate connection handling from message persistence.”

Redo arithmetic if they give different scale.

Core architecture

  1. Client → TLS → API / connection gateway
  2. Chat service validates, persists, enqueues delivery
  3. Message store (conversation-keyed)
  4. Push / gateway fan-out to online recipients; push notifications for offline
  5. Object store + CDN for media
  6. Presence service (ephemeral, often Redis-like)

Diagram narrative: ingest path vs delivery path vs history read path.

Fan-out: push vs pull

ApproachProsCons
Push fan-out on writeFast delivery for small groupsExpensive for huge groups
Pull on read / inboxCheaper writes for large roomsHigher read complexity
HybridFan-out small; pull for largeMore moving parts

Talk track:

“For 1:1 and small groups I’ll fan-out push to online sockets and write per-user inbox pointers. For very large rooms I’d switch to group-feed pull or hybrid.”

Candidates commonly report interviewers liking an explicit threshold discussion more than a single dogma.

Data model (starting point)

Ordering: server timestamp + tie-breakers; discuss clock skew briefly.

Delivery guarantees

Be precise:

Talk track:

“I’ll aim for at-least-once with idempotent clients. Exactly-once end-to-end is rarely free; I’ll say where duplicates can appear and how we dedupe.”

Presence, typing, media

Failure modes and tradeoffs

Ordering and history pagination

Clients paginate backward with a cursor (ts, messageId). Discuss:

Talk track:

“Timeline keys stay append-friendly; clients sync with cursors, and unacked local messages reconcile via clientMsgId.”

Multi-device sync

Users have phone + desktop. Options:

Keep this as a short extension after 1:1 delivery works.

Soft practice note

Chat rounds reward structured narration more than buzzwords. If you want timed rehearsal of this system design chat application talk track under pressure, Luna Interview is built for calm practice—not for inventing production war stories or violating interview rules.

Day-of checklist

Lead with clarity, then deepen. A clean 1:1 design with honest extensions beats an unfinished “full WhatsApp” sketch.