advanced

Backend performance

Server-side latency, throughput, profiling, data access, pooling, caching, and async bottlenecks in API and worker systems.

Backend performance interviews test latency, throughput, and resource efficiency for Node.js APIs and workers. Strong answers name queueing, event-loop blocking, database access shape, pooling limits, and cache consistency—not "add more RAM."

Subtopics: latency, throughput, profiling, database query optimization, connection pooling, backend caching, async bottlenecks.

On interviews: trace a slow endpoint through dependencies; explain p95 vs average; when pooling helps vs when query shape is wrong; how unbounded `Promise.all` hurts the event loop.

Common pitfalls: N+1 queries masked by cache; huge connection pools overloading Postgres; CPU profiles ignored in favor of guesswork; caching without TTL or invalidation.

The trade-off is response-time improvements versus consistency, operability, and database safety.

Checklist:

  • Measure end-to-end latency with percentiles.
  • Profile CPU, heap, and I/O wait.
  • Fix data access before scaling hardware.
  • Bound concurrency and pool sizes.