-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WithRetries Not Waiting Long Enough #501
Comments
Per Alvaro with Auth0 support:
|
Hi @GusPrice, I hope you're doing well! I tried to investigate this issue, but I wasn’t able to find any problems. Could you let me know if you're using a free tenant or an enterprise one? Thanks! |
Hi @developerkunal, That's unfortunate. We are on an enterprise account; but the tenant is a |
@developerkunal just following up here to see if you were able to look any further? |
Hi @GusPrice, We are currently looking into this! This issue may not be limited to the current SDK but could also affect other SDKs. |
Hello @developerkunal just circling back here! I understand that other SDKs may not account for this burst limit, but it would be great to have the functionality! |
Hi @GusPrice, I’m currently investigating this issue. So far, I haven’t found any specific error indicating that the burst limit has been reached—only messages stating that the global limit has been exceeded. I’m working on updating the retry logic to better handle rate limiting. However, one challenge is that rate limits vary based on the type of tenant. This means we can’t apply a blanket change without potentially causing issues for both normal and enterprise users. I’ll keep you posted as I make progress. Let me know if you have any additional insights! |
Yeah, makes a lot of sense. I appreciate you taking a stab at it. Maybe worth a conversation with the team that's responsible for the internal API and see if they could return some kind of different error messaging for global vs burst and levels of burst. More clear error messages and codes would make this a lot easier! |
@developerkunal awesome! I will read through the PR and give it a test for our use case this week. Will report back. Thank you! |
…Issue (#523) Co-authored-by: Ramya Anusri <[email protected]>
@developerkunal tested today and things are working as expected now with your change. Appreciate your help and willingness to refactor in this case! |
Checklist
Description
I am running into an issue where when I receive a 429 response from the management api, it seems the retries are not properly waiting to try again.
It seems that with this retry option, or just using the default retries I frequently run into an issue where the client gets a 429, but retries too soon. It seems like it's using the header value and getting to the final return in
backoffDelay()
ininternal/client/client.go
:But it seems like maybe this math isn't quite waiting long enough for things to have reset. Here's an example of the debug logs where you can see the reset header value is the current time the code is running at but it continues to fail.
Sample Output
Expectation
I would expect that 1 retry, 2 maximum would wait long enough to avoid this 429 burst limit of 10 that is specific to my ip address. Currently it seems to try again too soon relative the reset value returned by the header.
Reproduction
I am running something similar to the follow example code (simplified):
Auth0 Go SDK version
1.16.0
The text was updated successfully, but these errors were encountered: