Glossary · Performance

Backpressure

Backpressure is a signal from a slow consumer telling producers to slow down, preventing queues and memory from growing until a system collapses.

Updated November 4, 2026

Backpressure is a mechanism by which a component that cannot keep up pushes resistance back upstream, so producers slow down, wait or get rejected instead of piling up unbounded work. It turns an invisible overload into an explicit signal.

Why it matters

Without backpressure, a fast producer feeding a slow consumer fills a queue, then memory, then the whole process dies. Latency climbs long before the crash because every item waits behind the growing backlog. Bounded queues and explicit rejection keep latency predictable and let the failure stay local.

Backpressure shows up at every layer: TCP's receive window, bounded thread pools, streams that pause when a writer is full, message brokers that stop delivering until acknowledgments arrive, and HTTP servers that answer with 429 or 503.

Example

A Node.js stream pipes a fast file reader into a slow upload. writable.write() returns false when its buffer is full, which means stop writing until the drain event:

if (!writable.write(chunk)) {
  readable.pause();
  writable.once('drain', () => readable.resume());
}

Using pipeline() handles this for you.

Common mistakes

  • Using an unbounded queue "to be safe." It hides overload until memory runs out.
  • Retrying immediately when rejected, which adds load to the component that asked you to slow down.
  • Applying backpressure at only one layer while another buffers without limit.

Get notified when this term updates

Plus occasional practical tips on uptime and monitoring, nothing else. Unsubscribe anytime.

This page is general information written by our editorial team and updated when documentation changes. Servers and providers differ, so test changes safely first. See our editorial policy and disclaimer.