Customers were charged twice during an incident where the payment API timed out.
AdvancedTroubleshootingReliability Patterns in Production
Answer
Likely causes → The client retried a non-idempotent POST after a timeout, but the first request had actually succeeded on the server.
Diagnose → Match duplicate charges by customer and timestamp in payment logs; check retry configuration in the client library or mesh (VirtualService retries with retryOn: 5xx,reset).
Fix → Refund duplicates. Add idempotency keys: the client generates a key per logical payment, the server stores the result per key and returns it on duplicates. Remove automatic retries for non-idempotent calls at the mesh layer.
Prevent → Idempotency keys mandatory for all write APIs; retry policies reviewed per route.
More on Reliability Patterns in Production
Clients get 503s with body `upstream connect error or disconnect/reset before headers. reset reason: overflow`, and Envoy logs show flag `UO`.AdvancedNGINX ingress returns 504 and logs `upstream timed out (110: Connection timed out) while reading response header from upstream`.BeginnerAfter a 30-second database blip, Postgres keeps rejecting connections with `FATAL: sorry, too many clients already` for 20 minutes.AdvancedEvery rolling deploy produces a short burst of 502s on the AWS ALB.IntermediateRedis restarted and immediately the database CPU hit 100% and the site went down.AdvancedLogs fill with `CallNotPermittedException: CircuitBreaker 'inventory' is OPEN and does not permit further calls` long after inventory recovered.Intermediate