Sha256: 0a6c6d45c5969194b0b819d15096c0585f2f25f15cbbe93dc2156b7b29579b10
Contents?: true
Size: 785 Bytes
Versions: 15
Compression:
Stored size: 785 Bytes
Contents
require 'new_relic/agent/method_tracer' module QueueClassicNewRelic include NewRelic::Agent::Instrumentation::ControllerInstrumentation def new_relic_key "Custom/QueueClassicPlus/#{librato_key}" end def _perform(*args) opts = { name: 'perform', class_name: self.name, category: 'OtherTransaction/QueueClassicPlus', } perform_action_with_newrelic_trace(opts) do if NewRelic::Agent.config[:'queue_classic_plus.capture_params'] NewRelic::Agent.add_custom_parameters(job_arguments: args) end super end end QueueClassicPlus::Base.singleton_class.send(:prepend, QueueClassicNewRelic) end QueueClassicPlus::CustomWorker.class_eval do def initialize(*) ::NewRelic::Agent.manual_start super end end
Version data entries
15 entries across 15 versions & 1 rubygems