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

Add AssumeRole error cache #200

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

schleyfox
Copy link

When AssumeRole is successful, the success is cached for (by default) 15
minutes. On failure, there is no cache. In cases of misconfiguration,
this can result in a large number of AssumeRole calls against the AWS
API, which, in extreme cases, can result in API rate limiting, causing
other applications in the AWS account to experience failures.

This adds a negative cache on AssumeRole to prevent error cases from
spamming the API. This is set to 0 by default to preserve existing behavior,
but a value of 30 seconds to 1 minute would be reasonable.

When AssumeRole is successful, the success is cached for (by default) 15
minutes.  On failure, there is no cache.  In cases of misconfiguration,
this can result in a large number of AssumeRole calls against the AWS
API, which, in extreme cases, can result in API rate limiting, causing
other applications in the AWS account to experience failures.

This adds a negative cache on AssumeRole to prevent error cases from
spamming the API.
@coveralls
Copy link

Coverage Status

Coverage decreased (-0.3%) to 19.474% when pulling 46bce9d on schleyfox:add-negative-cache into 80efbb1 on jtblin:master.

@schleyfox
Copy link
Author

@jrnt30 can you look at this?

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

Successfully merging this pull request may close these issues.

None yet

2 participants