Commit f59e203
authored
fix(provider): overhaul openai-subscription retry policy (#32)
Statusless errors like service_unavailable_error/server_is_overloaded
failed fatally because retriability was an exact-match allowlist.
Classification now defaults to retrying and excludes permanent errors
by heuristic instead.
- retry budget 10m -> 24h, time-driven only (MAX_RETRIES removed)
- backoff cap 30s -> 60s; per-attempt 10m guard on send/credentials
- honor x-ratelimit-reset-* on 429 over Retry-After: pace waits at
10m and retry until reset + 10m grace, clamped to the 24h budget
- cap all server delay hints at 10m
- reopen_stream keeps request_context in place so a cancelled reopen
stays retryable from the first-event timeout path1 parent 557b54b commit f59e203
3 files changed
Lines changed: 327 additions & 129 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| 88 | + | |
88 | 89 | | |
89 | 90 | | |
90 | 91 | | |
| |||
0 commit comments