Sha256: 962bf64c3260ad7e16e3e3c785d62b6581efa6cb3639a1193d1113a7b6c66cc8
Contents?: true
Size: 643 Bytes
Versions: 7
Compression:
Stored size: 643 Bytes
Contents
if defined?(::Unicorn) Appsignal.logger.info('Loading Unicorn integration') # Make sure the appsignal is started and the last transaction # in a worker gets flushed. # # We'd love to be able to hook this into Unicorn in a less # intrusive way, but this is the best we can do given the # options we have. class Unicorn::HttpServer alias_method :original_worker_loop, :worker_loop def worker_loop(worker) Appsignal.forked original_worker_loop(worker) end end class Unicorn::Worker alias_method :original_close, :close def close Appsignal.stop original_close end end end
Version data entries
7 entries across 7 versions & 1 rubygems