SRE & Observability (50 Qs)•Part 3: Advanced Internals, Scale & Production Patterns (Senior / Lead)
Circuit Breakers and Bulkheading: Preventing cascading failures.
senior Levelsre-observabilityAdvanced Internals
In Simple Words:
- Circuit Breaker (Envoy / Resilience4j):
- If downstream Payment Service fails 50% of requests over 10 seconds, the circuit Opens.
- Subsequent requests fail fast immediately without waiting for timeouts, allowing the downstream database to recover.
- Transitions to Half-Open after a cool-off window to test if health is restored.
- Bulkheading: Isolating thread pools and connection limits per dependency. If the recommendation engine hangs, it consumes only its dedicated 10 threads; core checkout processing continues operating with its own isolated 50 threads.