8:54 AM ·

Why our retry logic made the outage worse

placeholder

Three minutes into the incident, the dashboards looked worse than when we started. Not because the database recovered slower, but because every client that failed a request was now retrying it, immediately.

Most retry logic starts life looking simple: catch a failure, wait a fixed amount, try again. It works fine in isolation. It fails badly under load, because every failing client synchronizes its retries against the same recovering service, a thundering herd generated by the very code meant to add resilience.

Exponential backoff with full jitter turned our recovery time from eleven minutes into ninety seconds, without changing anything on the database side.

0 comments