Respect Google+ API rate limits
rjoonas opened this issue · 0 comments
rjoonas commented
We have an application that utilizes this module and deals with quite a few requests. At peak traffic it will sometimes exhaust the Google+ API quota for the application. When this happens, express-gauth's error handler will log the following (at index.js:130):
GAuth error { GooglePlusAPIError: User Rate Limit Exceeded
message: 'User Rate Limit Exceeded',
name: 'GooglePlusAPIError',
code: 403 }
It'd be useful if we could provide express-gauth with our Google+ API quotas and it would throttle requests. Retrying with an exponential backoff delay might help as well?
Default quotas I'm currently seeing in Google Developer console for Google+ API:
- 20 000 000 sign-in queries per day
- 500 sign-in queries per 100 seconds per user
- 25 000 sign-in queries per 100 seconds
Of course the developers can always request a more lofty quota from Google. :)