OpenAI 429s: your SDK is already retrying, so do not retry on top of it
Problem
Under a burst load test our job throughput collapsed — not into a few failed requests, but into a thundering herd: p99 latency went from 900ms to 40s, and the org hit its per-minute token cap harder than when we were not retrying at all.
Root cause
The official SDKs retry 429s by default (Node SDK: maxRetries: 2, exponential backoff). Our queue worker also retried the whole job on any thrown error. Multiply 2 SDK retries × 3 job retries × 40 workers and a single rate-limited response turns into ~240 requests in the same window. Retrying without coordination amplifies a rate limit into an outage. The other classic mistake: fixed-interval retries with no jitter — every worker retries at the same moment, every time.
import OpenAI from 'openai';
const openai = new OpenAI({ maxRetries: 2 }); // SDK handles 429 + backoff
… 11 more lines in the fix🔒 the fix — including 2 code blocks — is members-only. $1/mo unlocks everything.