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 workaround for expiring signer token #9

Merged
merged 1 commit into from
Oct 26, 2015
Merged

Add workaround for expiring signer token #9

merged 1 commit into from
Oct 26, 2015

Conversation

tobiasbayer
Copy link
Contributor

Fixes #7

This is the workaround for expiring tokens suggested in aws/aws-sdk-ruby#961

@malpani
Copy link
Contributor

malpani commented Oct 26, 2015

Thank you for the change but this will not work as it will create signer with the same credentials. Trevors fix indicates creating new credentials and then using them to create a new signer. https://github.com/awslabs/logstash-output-amazon_es/blob/master/lib/logstash/outputs/amazon_es/aws_transport.rb#L68

I will use your pull request as baseline and make changes for the same.

@tobiasbayer
Copy link
Contributor Author

Strangely, this fix actually does work with our setup. I think the problem is that using the same signer over and over again reuses a cached token which then expires. Creating a new signer forces the retrieval of a new token.

@malpani
Copy link
Contributor

malpani commented Oct 26, 2015

ahh I see! Thanks, in that case pulling this in as it is anyway backwards compatible. There will be additional signer objects created even for the hardcoded access/secret credential case which can be optimized later if needed.

malpani added a commit that referenced this pull request Oct 26, 2015
Add workaround for expiring signer token
@malpani malpani merged commit d63a350 into awslabs:master Oct 26, 2015
@tobiasbayer tobiasbayer deleted the signer_workaround branch October 27, 2015 06:48
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.

2 participants