What is back-pressure in distributed systems?

Why Interviewers Ask This

This is a classic screening question for System Design roles. Hiring managers ask it early in interviews to gauge your baseline understanding and determine if you can communicate technical concepts clearly.

Answer

Back-pressure is a flow control mechanism where a slower consumer signals an upstream producer to slow down, preventing the consumer from being overwhelmed and crashing. Without back-pressure, a fast producer overwhelming a slow consumer causes memory exhaustion, request queuing, and eventual failure. Analogies: a garden hose nozzle controlling water flow; car traffic congestion spreading back from a bottleneck. Strategies: (1) Blocking/synchronous back-pressure: the producer waits until the consumer is ready — simple but creates tighter coupling (TCP flow control window is an example); (2) Message queue with bounded queue: if the queue is full, the producer blocks or drops/rejects messages — the queue acts as a buffer with a capacity limit; (3) Rate limiting upstream: signal the producer via HTTP 429 (rate limit) or queue depth metrics to reduce throughput; (4) Load shedding: when overwhelmed, drop non-critical requests rather than crashing; (5) Reactive Streams: a standard for async stream processing with non-blocking back-pressure (Java: Project Reactor, RxJava; implemented in Akka Streams). In practice: Kafka consumers control their read rate independently; Node.js streams have pause()/resume() for back-pressure. Back-pressure is a fundamental concept in designing resilient data pipelines, streaming systems, and microservices under variable load.

Pro Tip

Back up your answer with a specific project or situation. Saying 'In my last System Design project, I used this when...' immediately makes your answer more credible and memorable.