Last active
August 29, 2015 14:15
-
-
Save ardeearam/f579a1392b4ddfb65e8f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is how to iterate over Amzon SDK version 2. | |
# Notice that the actual data is contained inside the "data" method. | |
# This is the one that got me, and this is not documented anywhere. | |
sqs = Aws::SQS::Client.new(region: 'ap-southeast-1') | |
output ="" | |
sqs.list_queues.each do |response| | |
output += response.data.to_json + "\n" | |
end | |
puts output |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment