Skip to content
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

Overhaul rate limited request handling #210

Open
baumatron opened this issue May 5, 2017 · 0 comments
Open

Overhaul rate limited request handling #210

baumatron opened this issue May 5, 2017 · 0 comments

Comments

@baumatron
Copy link
Contributor

baumatron commented May 5, 2017

Only simple analysis and funnel handle a 429 rate-limiting response and 503 errors aren't handled at all.

The current model for the SDK is to just record a 4xx http return code, and ignore client query requests if a specific query has failed 10 times in the past 3600 seconds. This isn't really retry logic, but barring a client from continuing to make query requests until 3600 seconds have elapsed. It's also recording a per-query attempt, while the rate-limit applies to the entire project.

At a minimum, that logic should be updated to include all analysis types that fall into the rate-limited category here: https://keen.io/docs/api/#limits.

A more complete solution might be to implement something in the SDK to allow for automatic retry attempts by introducing a delay and retrying up to a certain number of times before failing back to the client.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant