Skip to content

Exponential backoff for 429 errors#542

Merged
irees merged 3 commits intomainfrom
backoff-429
Dec 28, 2025
Merged

Exponential backoff for 429 errors#542
irees merged 3 commits intomainfrom
backoff-429

Conversation

@irees
Copy link
Copy Markdown
Contributor

@irees irees commented Dec 28, 2025

No description provided.

Copilot AI review requested due to automatic review settings December 28, 2025 01:25
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR implements exponential backoff retry logic for HTTP 429 (Too Many Requests) rate limiting errors. The implementation adds configurable retry behavior with support for the Retry-After header, exponential backoff with jitter, and proper context cancellation handling.

  • Adds retry configuration fields (MaxRetries, InitialBackoff, MaxBackoff) to the Http struct with sensible defaults
  • Implements exponential backoff with jitter for 429 errors, respecting the Retry-After header when provided
  • Refactors DownloadAuth to retry failed requests up to maxRetries times with appropriate backoff delays

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@irees irees merged commit 5c939fa into main Dec 28, 2025
12 checks passed
@irees irees deleted the backoff-429 branch December 28, 2025 02:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants