Navigation Menu

Skip to content

Commit

Permalink
Output more helpful messages for "verbose" mode
Browse files Browse the repository at this point in the history
  • Loading branch information
piroor committed Apr 21, 2015
1 parent 61bfea2 commit 010616d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/droonga/serf.rb
Expand Up @@ -238,9 +238,13 @@ def ensure_restarted(*nodes, &block)
yield # the given operation must restart the service.

while Time.now - start_time < CHECK_RESTARTED_TIMEOUT
puts "Checking nodes are restarted or not:" if @verbose
targets.reject! do |target|
name = target[:serf].get_tag(Tag.internal_node_name)
name != target[:previous_name]
restarted = name != target[:previous_name]
puts " #{name} vs #{target[:previous_name]} => " +
"#{restarted ? "restarted" : "not yet"}" if @verbose
restarted
end
break if targets.empty?
sleep(CHECK_RESTARTED_INTERVAL)
Expand Down

0 comments on commit 010616d

Please sign in to comment.