-
Notifications
You must be signed in to change notification settings - Fork 53
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
Add Support to access Throttle Headers #112
Comments
@markalanevans at the moment we don't have a way to access these directly, and is one of the reasons why we need to rework that side of the library. This is something we will be addressing soon, but if you have the time and bandwidth I'll be happy to review a PR on this. 👍 |
+1 I was thinking these should be bubbled up in a custom exception indicating to the caller that they were "rate limited", as easy to access properties. Or at minimum as some dictionary entries like other errors are returned. |
In case you expose those headers, I suggest using this spec https://tools.ietf.org/html/draft-polli-ratelimit-headers-03 which is currently supported by various api gateway (kong, envoy proxy, redhat-3scale, ...) and some client libraries. it just expresses X-RateLimit-Reset in delta-seconds instead of a timestamp: this reduces clock-skew issues and "thundering herd" problems at begin of period |
@travega @khalilovcmd so how do i get access to the headers?
The text was updated successfully, but these errors were encountered: