GuideIntermediate

Resilience And Reliability Patterns

Learn to make a distributed system survive the failure of its parts: timeouts, retries with backoff and jitter, idempotency, circuit breakers, bulkheads, graceful degradation, and load shedding. The guide's core is partial failure — in a distributed system something is always down or slow — and how to stop a dependency's failure from taking down the whole system. You work through a single case study from start to finish: Mercado's checkout flow, where `orders` calls `payments` and `shipping`, and those dependencies genuinely fail and slow down. Everything is simulated and measured in Python with configurable failure rates and latency: you'll measure thread exhaustion without a timeout, a retry storm without backoff, how many calls a circuit breaker saves when a service is dead, how a bulkhead isolates a slow dependency so it doesn't drain the others, and the checkout's success rate before and after hardening it. The capstone combines every pattern over Mercado's full checkout flow and measures the result.

64
lessons
8
modules
English · Spanish
available in
Yes
certificate
Free
access
NIEVA

Outcomes

What you'll be able to do

  • Understand partial failure and cascading failure: why something is always down or slow in a distributed system
  • Set correct timeouts (connection and read) and measure how they prevent thread/connection exhaustion
  • Retry with exponential backoff and jitter to avoid a retry storm, and know when NOT to retry
  • Implement idempotency with an `idempotency_key` so a retry doesn't charge or execute an operation twice
  • Apply circuit breakers (`CLOSED`/`OPEN`/`HALF_OPEN` states) to stop hammering a dead service, and measure automatic recovery
  • Isolate dependencies with bulkheads so a slow one doesn't drain the pool for the others
  • Design graceful degradation and load shedding so the system fails soft, not hard, under overload
  • Harden a real flow end to end by combining every pattern, measuring success rate and latency before and after

Before you start

What you need to bring

It's for you if...

  • Backend devs whose service calls unreliable dependencies (network, third parties, other microservices) and don't know how to harden it
  • Devs who've already wrapped a `try/except` around an external call but never measured whether it actually helps
  • Anyone who needs to understand circuit breakers, bulkheads, or backoff before reaching for a library like resilience4j or Polly
  • Teams that suffered a cascading failure and want to learn to design against it with judgment, not patches

Requirements and materials

  • Basic Python (every simulation and measurement in this guide runs in Python)
  • Having built a backend service that calls another service or external API
  • No prior experience with resilience libraries or distributed systems required

Content

The syllabus, module by module

Open any of them to see its lessons.

Common questions

What people usually ask

Start whenever you like

Reviews

What students say

These reviews are from enrolled students who completed at least 50% of the course. We moderate reviews only on content grounds (spam, offensive language, personal data), never for being critical or negative.

No approved reviews yet.

Be the first to share your experience!