Skip to content
Go back

80/20 Of The Week: Idempotency and Resilience

Edit page

80/20 Of The Week 🗣️ … Idempotency and Resilience in systems (how to use “retry” properly)

I swear these are “simple” to understand the basics of but just sound tough xD

Let’s say an issue occurs in the system and a timeout happens. Client retries. And then… you charge the card twice or you order the same thing from Temu basket twice 😭

That’s why idempotency exists:

Idempotency = same request 100x → same result 1x… that is basically it…

How it works in real systems (simple)

Client sends an Idempotency-Key (usually a UUID) with a “dangerous” request like: POST /payments, POST /orders, POST /transfers… basically FINAL steps of operations like orders or similar.

Server does this:

And yes… dedup storage can literally be just a table. Example: idempotency_keys table (Postgres / MySQL / Oracle)

Where do you store it?

Most teams do:

Retries are good… until they aren’t.

If you retry:

Usual “minimal but solid” combo:

  1. Timeouts (client + server)
  2. Retry with exponential backoff + jitter
  3. Circuit breaker (stop the bleeding)
  4. Bulkhead (isolate thread pools)
  5. Rate limiting (protect the system)

Quick consistency note

The moment you have retries + queues + async workflows, you’re living in “duplicates can happen” land. So your safety net becomes: idempotency + good retry policy + clear consistency expectation (strong vs eventual)

If you build big systems, assume the worst and design for it 😄

ALSO… “idempotent” means: the ability of a system to produce the same outcome, even if the same file, event or message is received more than once… shout out to Google!

Idempotency in Systems


Edit page
Share this post on:

Previous Post
80/20 Of The Week: Partitioning and Sharding
Next Post
80/20 Of The Week: Event-Driven Architecture (EDA)