Skip to content

Commit

Permalink
Clearer comment for .kill_self
Browse files Browse the repository at this point in the history
  • Loading branch information
jclem committed Mar 13, 2013
1 parent 37a0d61 commit d70f65c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions lib/unicorn/worker_killer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@ class << self
attr_accessor :configuration
end

# Self-destruction by sending the signals to myself. The process sometimes
# doesn't terminate by SIGQUIT, so this tries to send SIGTERM and SIGKILL
# if it doesn't finish immediately.
# Kill a the current process by telling it to send signals to itself. If
# the process isn't killed after `configuration.max_quit` QUIT signals,
# send TERM signals until `configuration.max_term`. Finally, send a KILL
# signal. A single signal is sent per request.
# @see http://unicorn.bogomips.org/SIGNALS.html
def self.kill_self(logger, start_time)
alive_sec = (Time.now - start_time).to_i
Expand Down

0 comments on commit d70f65c

Please sign in to comment.