Skip to content

Commit

Permalink
ec2::machine: increasing wait interval, to reduce potential for inter…
Browse files Browse the repository at this point in the history
…mittent errors to bomb run
  • Loading branch information
temujin9 committed Feb 15, 2013
1 parent 5148dca commit 9213143
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/ironfan/provider/ec2/machine.rb
Expand Up @@ -161,7 +161,13 @@ def self.create!(computer)
computer.machine = machine
remember machine, :id => computer.name

fog_server.wait_for { ready? }
# AWS sometimes takes too long to respond for this block's liking.
# Expand its wait interval, so that it doesn't just bomb out
# after three quick failures in succession.
# For more info, see:
# - http://rubydoc.info/gems/fog/1.9.0/Fog/Model#wait_for-instance_method
# - https://github.com/fog/fog/blob/master/lib/fog/core/wait_for.rb
fog_server.wait_for(Fog.timeout, 5) { ready? }
end

# tag the computer correctly
Expand Down

0 comments on commit 9213143

Please sign in to comment.