Skip to content

Conversation

@iskorotkov
Copy link

Changes:

  • added retries on 429 status code (that use value from Retry-After header)
  • added retries on 429|500+ status codes (that use exponential backoff)
  • unified tests and added tests for new functionality

Reasoning:

  • in my application I execute requests in parallel, which leads to lots of 429s due to rate limiting. My PR enables automatic retries on rate limits (429) and server errors (500+) for HTTP transport

I'm looking for feedback. Current implementation is simple and straightforward, but it is able to solve problems that I encountered. I can try to implement similar mechanism for WS transport if this PR gets approved and merged.

@iskorotkov iskorotkov marked this pull request as draft January 9, 2024 16:59
@iskorotkov iskorotkov marked this pull request as ready for review January 10, 2024 17:38
@iskorotkov iskorotkov force-pushed the feat/add-http-transport-retries branch from bfec9a8 to f8d1ac9 Compare January 4, 2025 09:38
@iskorotkov iskorotkov force-pushed the feat/add-http-transport-retries branch from 20f73d2 to e08f69c Compare January 4, 2025 11:31
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