Real-Time and Streaming System Design Questions

Designing client-facing, always-on live delivery systems: real-time communication transports (WebSockets, server-sent events, long-polling, WebRTC, MQTT), connection lifecycle and scaling for millions of persistent connections, presence, pub/sub fan-out to online users, chat and notifications, live feeds and tickers, real-time collaboration (CRDT vs OT, offline sync and reconciliation), and live and on-demand video delivery (ingest, transcoding, adaptive bitrate, CDN delivery, low-latency protocols, playback entitlement and content protection). Covers latency budgets, per-client ordering, delivery guarantees across disconnect and reconnect, per-client backpressure, capacity estimation for connection fleets, authentication, authorization, and revocation for real-time channels and premium content, and operational readiness (SLOs and error budgets, observability and incident response, rate limiting, safe rollout, and load and chaos testing) for live-delivery platforms. Data-pipeline stream processing (Kafka or Flink jobs, windowed aggregation, exactly-once pipelines, real-time analytics ingestion) is out of scope.

MediumTechnical
60 practiced

Explain strategies to provide at-least-once, at-most-once and exactly-once semantics for message delivery in a realtime system. Include practical techniques for ordering (per-client sequencing, partitioned global sequence numbers, vector clocks) and discuss implementation complexity, metadata overhead, and performance trade-offs for each approach.

MediumSystem Design
62 practiced

Describe approaches to broadcast a piece of data (e.g., live sports update) to millions of clients with low latency: origin server fan-out, broker-based pub/sub, hierarchical fan-out (multi-level brokers), multicast (on LAN), and CDN-assisted push. For each approach discuss cost, latency, state management, and when it's most appropriate.

HardSystem Design
61 practiced

Design a multi-CDN traffic-steering architecture to optimize availability and cost. Include real-time telemetry ingestion, a steering decision engine that chooses between failover and load-splitting, your chosen steering mechanism and why, and the metrics you would use to evaluate provider performance.

MediumTechnical
53 practiced

How would you implement authentication and authorization for long-lived WebSocket connections in a multi-tenant SaaS product? Cover initial token exchange during the handshake, token refresh for long-lived sessions, per-message authorization checks where needed, handling token revocation or tenant deprovisioning (including third-party API consumers, not just browser clients), and techniques to minimize re-auth overhead while ensuring security.

HardTechnical
46 practiced

Design and provide pseudocode for a server-side backpressure policy that, upon crossing a memory threshold, selectively drops, compresses, or aggregates messages per-client priority. The policy should preserve high-priority messages, emit metrics for dropped messages, and support graceful degradation. Explain rollout strategy and safety guards to avoid broad customer impact.

Unlock Full Question Bank

Get access to all Real-Time and Streaming System Design interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.