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

Region immunity #5

Open
vanch opened this issue Aug 27, 2015 · 3 comments
Open

Region immunity #5

vanch opened this issue Aug 27, 2015 · 3 comments

Comments

@vanch
Copy link
Contributor

vanch commented Aug 27, 2015

After hours of debug I found some issue.

Environment:
Ruby 2.0.0p645
Amazon Linux AMI release 2015.03
zabbix-cloudwatch 0.1.0

Problem:
Always empty response with right request.

zabbix-cloudwatch --aws-access-key $AWSACCESSKEY --aws-secret-key $AWSSECRETKEY --aws-region eu-central-1 --namespace "AWS/RDS" --metricname FreeStorageSpace --dimension-name "DBInstanceIdentifier" --dimension-value somename

gives me nothing, just empty datapoint array.

Investigation:
I've been found similar issues when region is not set, so I checked. In main binary that's ok eu-central-1, but when you going lower, to get_aws_options function, there is if with && which gives you on p options.key?"aws-region" && options['aws-region'] != '' - false. I can't understand why it's possible.

Solution:
I've changed && to and and everything works. In this statement there is no difference between && and and so it's ok.

@randywallace
Copy link
Owner

@randywallace
Copy link
Owner

#7 should resolve this

@tiago-cruz-movile
Copy link

Good! confirmed here the change from && to and and now is working 👍

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

No branches or pull requests

3 participants