NestJS · Senior · Question 67 of 75
How do you limit the impact of a slow downstream service on a Nest API's thread of execution?
- 1Increase the Node.js thread pool to 1000
- ✓Correct answer: Bound concurrent calls per dependency (bulkhead), add timeouts, and return cached or degraded data when possible
- 3Make every call synchronous
Explanation
Without limits, waiting calls accumulate memory and sockets until the whole service degrades.