# File lib/raemon/master.rb, line 76 def worker_heartbeat!(worker) return if timeout <= 0 @last_pulse ||= 0 begin if Time.now.to_i > @last_pulse + (timeout/2) # Pulse (our lifeline to the master process) @last_pulse = Time.now.to_i @p = 0 == @p ? 1 : 0 worker.pulse.chmod(@p) # Make sure master is still around otherwise exit master_pid == Process.ppid or return end rescue => ex if worker.pulse logger.error "Unhandled listen loop exception #{ex.inspect}" logger.error ex.backtrace.join("\n") instrument 'error', :error => ex end end end