def setup_traps
      ['INT', 'TERM'].each do |sig|
        old = trap(sig) do
          EM.next_tick do
            begin
              terminate do
                TERMINATE_BLOCK.call
                old.call if old.is_a? Proc
              end
            rescue Exception => e
              ErrorTracker.log(self, "Failed in termination", e)
            end
          end
        end
      end
      true
    end
def setup_traps
      ['INT', 'TERM'].each do |sig|
        old = trap(sig) do
          EM.next_tick do
            begin
              terminate do
                TERMINATE_BLOCK.call
                old.call if old.is_a? Proc
              end
            rescue Exception => e
              ErrorTracker.log(self, "Failed in termination", e)
            end
          end
        end
      end
      true
    end
Setup signal traps

 === Return
 true:: Always return true