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

Github Rate Throttle #31

Open
jrtechs opened this issue Dec 29, 2019 · 0 comments
Open

Github Rate Throttle #31

jrtechs opened this issue Dec 29, 2019 · 0 comments
Labels
enhancement New feature or request help wanted Extra attention is needed research

Comments

@jrtechs
Copy link
Owner

jrtechs commented Dec 29, 2019

Occasionally when generating a large profile(like this one), GitHub will send a 403 in response. Currently, our API just ignores one and sends an empty list, but doesn't store it in the cache.

To fix this issue we will probably have to start to throttle how fast we are making queries for large profiles when we get a 403 we just wait for a second or two and try again. In their documentation we are allowed 5000 queries per hour.

We should also start logging how many queries we make to GitHub so that we can figure out if we are approaching the limit.

Ways to get more queries:

  • We could use the client to make some queries that we don't have on our behalf and send the responses back to the server for caching (we could then sample these queries to make sure they are valid). This would help supplement our cause because every potential user has 60 queries that they can make.
  • For larger more intensive graphs we decide to make in the future (stuff to do with user/repository events), we may have to have the user authenticate with our application so the requests are associated with their account.
@jrtechs jrtechs added enhancement New feature or request research help wanted Extra attention is needed labels Dec 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed research
Projects
None yet
Development

No branches or pull requests

1 participant