One slow dependency takes down your entire system. Why does that happen and how do you prevent it?
What they are really testing: Whether you understand cascading failure mechanics: resource exhaustion propagating backwards through a call graph. This is the difference between someone who has read about resilience and someone who has watched it happen.
A real interview question
One slow dependency takes down your entire system. Why does that happen and how do you prevent it?
What most people say
drag me
“We should add retries so that requests to the slow dependency eventually succeed.”
Retries against an overloaded dependency are actively harmful: they multiply load on the thing already failing, which is a well-known way to turn a partial degradation into a total outage and to prevent recovery.
The follow-ups they ask next
How do you choose a timeout value?
From the dependency latency distribution, typically a bit above p99, so normal requests are unaffected but pathological ones are cut. Then ensure the caller timeout exceeds the callee, or you waste work the callee still completes.
What is a retry budget and why does it matter?
A cap on retries as a percentage of total requests, say 10%. It preserves retries for transient blips while making it impossible for retry traffic to multiply load during a real outage.
What the interviewer is listening for
- Explains resource exhaustion propagating backwards
- Knows slow is more dangerous than down
- Raises retry amplification unprompted
What sinks the answer
- Suggests retries as the primary fix
- No timeouts in the answer
- Cannot explain the propagation mechanism
If you genuinely do not know
Say this instead of freezing. Reasoning out loud from what you do know beats silence every single time, and a good interviewer is listening for exactly that.
“The mechanism is [callers hold threads and connections while waiting, so a slow dependency exhausts their pools, and it walks up the graph]. [Slow is worse than down, since a refused connection frees resources instantly.] Controls: [aggressive timeouts first], [bulkheads so each dependency has its own pool], [circuit breakers], [graceful degradation]. Retries need [backoff, jitter and a budget] or they amplify the outage.”
Keep going with troubleshooting
Junior
A developer says the build passes locally but fails in CI. How do you debug that?
Junior
A production server is failing writes. Disk is 100% full. Walk me through what you do.
Junior
At midnight everything started failing with TLS errors. What happened and what do you do?
Mid
A pod is in CrashLoopBackOff after a deploy. Walk me through your debugging, command by command.
Mid
The deploy reports success, pods are Running, but users get 502s. Where do you look?
Mid
A Kubernetes node goes NotReady and pods are stuck Terminating. What is happening and what do you do?
Knowing the answer is not the same as recalling it under pressure
Sign in to send the questions you fumble to spaced recall, so they come back right before you would forget them, and learn the concepts behind them with hands-on labs.
Start free