Sha256: ba614071351bfd3d23b0400259d3405a39bf2b796ffe6fd6897acac0d3ba7b44
Contents?: true
Size: 828 Bytes
Versions: 7
Compression:
Stored size: 828 Bytes
Contents
if defined?(::Resque) Appsignal.logger.info('Loading Resque integration') module Appsignal module Integrations module ResquePlugin def around_perform_resque_plugin(*args) Appsignal.monitor_transaction( 'perform_job.resque', :class => self.to_s, :method => 'perform' ) do yield end end end end end # Set up IPC Resque.before_first_fork do Appsignal::IPC::Server.start if Appsignal.active? end # In the fork, stop the normal agent startup # and stop listening to the server Resque.after_fork do |job| Appsignal::IPC.forked! if Appsignal.active? end # Extend the default job class with AppSignal instrumentation Resque::Job.send(:extend, Appsignal::Integrations::ResquePlugin) end
Version data entries
7 entries across 7 versions & 1 rubygems