InterviewStack.io LogoInterviewStack.io

Fault Tolerance and Failure Scenarios Questions

Designing systems resilient to component failures: timeouts, retries with exponential backoff, circuit breakers, bulkheads. Discuss cascading failure prevention and graceful degradation. At Staff level, demonstrate thinking about multi-layer failures (service failures, database failures, network partitions) and how to detect and recover from them.

EasyTechnical
78 practiced
Implement a function in Python that returns the next retry delay using exponential backoff with full jitter. Signature: def next_delay(attempt: int, base: float = 0.1, max_delay: float = 10.0, seed: int = None) -> float. The function must be deterministic when seed is provided and ensure delay in [0, min(max_delay, base * 2**attempt)]. Include a brief comment explaining your approach.
MediumSystem Design
64 practiced
Design a fallback where a service runs in cache-only read mode when its primary datastore is unavailable. Requirements: serve cached reads where possible, avoid serving data older than configured TTL, reject writes safely, and minimize inconsistent reads. Describe components, cache priming/invalidation, and failure modes.
HardSystem Design
84 practiced
Design capacity planning and failover strategies to keep a service operating during an entire availability zone (AZ) outage. Include provisioning strategies (over-provision vs warm standby), autoscaling policies, cross-AZ DNS/load-balancer changes, and detection/rebalancing timelines to restore target capacity within minutes.
MediumTechnical
80 practiced
Design liveness and readiness probes for a microservice that depends on cache, auth service, and message queue. Explain how you would detect partial degradation versus full service failure, avoid false positives, and design probe endpoints, latency thresholds and retry behavior suitable for Kubernetes or similar orchestrators.
EasyTechnical
81 practiced
A popular cache key expires simultaneously and causes a sudden DB spike (thundering herd). Describe multiple approaches to prevent this as an SRE: jittered TTLs, request coalescing (single flight), mutexing fetches, stale-while-revalidate, proactively refreshing hot keys, and how to choose among them based on service constraints.

Unlock Full Question Bank

Get access to hundreds of Fault Tolerance and Failure Scenarios interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.