flapjack 0.6.26 → 0.6.27

Sign up to get free protection for your applications and to get access to all the features.
@@ -27,6 +27,7 @@ fi
27
27
  # Evaluate command
28
28
  case "$1" in
29
29
  start)
30
+ rbenv shell 1.9.3-p125
30
31
  flapjack --config /etc/flapjack/flapjack-config.yaml --daemonize
31
32
  RETVAL=$?
32
33
  ;;
@@ -19,6 +19,7 @@ require 'yajl/json_gem'
19
19
  require 'flapjack/data/entity_check'
20
20
  require 'flapjack/pikelet'
21
21
  require 'flapjack/utility'
22
+ require 'flapjack/version'
22
23
 
23
24
  module Flapjack
24
25
 
@@ -162,8 +163,9 @@ module Flapjack
162
163
 
163
164
  when command =~ /^identify$/
164
165
  t = Process.times
165
-
166
- msg = "Flapjack process #{Process.pid} on #{`hostname -f`.chomp} \n"
166
+ boot_time = Time.at(@redis_handler.get('boot_time').to_i)
167
+ msg = "Flapjack #{Flapjack::VERSION} process #{Process.pid} on #{`hostname -f`.chomp} \n"
168
+ msg += "Boot time: #{boot_time}\n"
167
169
  msg += "User CPU Time: #{t.utime}\n"
168
170
  msg += "System CPU Time: #{t.stime}\n"
169
171
  msg += `uname -a`.chomp + "\n"
@@ -275,9 +277,11 @@ module Flapjack
275
277
  logger.debug('jabber notification event received')
276
278
  logger.debug(event.inspect)
277
279
  if 'shutdown'.eql?(type)
278
- EM.next_tick do
279
- # get delays without the next_tick
280
- close # Blather::Client.close
280
+ if should_quit?
281
+ EM.next_tick do
282
+ # get delays without the next_tick
283
+ close # Blather::Client.close
284
+ end
281
285
  end
282
286
  # FIXME: should we also set something so should_quit? returns true
283
287
  # to prevent retrieving more notifications from the queue while closing?
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
3
  module Flapjack
4
- VERSION = "0.6.26"
4
+ VERSION = "0.6.27"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flapjack
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.26
4
+ version: 0.6.27
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: