Backend developer interview question · 5+ years
Your service calls three internal APIs and one is intermittently slow. What do you build in?
The strongest answer
A timeout shorter than your own deadline, limited retries only for idempotent calls with backoff and jitter, a circuit breaker so you stop hammering a dead dependency, and a degraded response when it is unavailable
Why it works
Right, and the degraded path is what turns their outage into a smaller one for you.
What a good answer covers
- Timeout every outbound call.
- Retry only what is idempotent, with jitter.
- Break the circuit on sustained failure.
- Design what degraded looks like.
Answers that fall short
- Close, but not the strongest: Unlimited retries, so a request always eventually succeeds
Unlimited retries turn a blip into a self-inflicted denial of service. - Weak: A longer timeout so the slow calls have time to finish
That makes their slowness your slowness. - Red flag: Nothing — the platform retries failed requests
Blind platform retries can amplify the problem.
Who gets asked this
More Backend developer questions
- You are asked to make a payments service active in two regions. What is the first design question?
- Product wants dashboards over the transactional database. When do you say no and build a separate analytical…
- Design multi-tenancy for a product where some tenants are regulated.
- One endpoint renders PDFs and pegs a core for about two seconds. It is stalling an otherwise healthy Node…
- Your worker cannot keep up with the producer and memory climbs. What is the right answer?
- A payment endpoint can be retried by clients. How do you stop double charges?
- What is a cell-based architecture and when is it worth the complexity?
- How do you model a warehouse so analysts can answer new questions without you?