Module: NewRelic::Agent::Instrumentation::Resque::Chain

Defined in:
lib/new_relic/agent/instrumentation/resque/chain.rb

Class Method Summary collapse

Class Method Details

.instrument!Object



8
9
10
11
12
13
14
15
16
17
18
# File 'lib/new_relic/agent/instrumentation/resque/chain.rb', line 8

def self.instrument!
  ::Resque::Job.class_eval do
    include NewRelic::Agent::Instrumentation::Resque

    alias_method(:perform_without_instrumentation, :perform)

    def perform
      with_tracing { perform_without_instrumentation }
    end
  end
end