Sha256: fe1f9cf475243b59d91467488def63d4b977d7e07bb2309da9ebbc6fe365b749
Contents?: true
Size: 837 Bytes
Versions: 2
Compression:
Stored size: 837 Bytes
Contents
if defined? Appsignal ::Appsignal.logger.info('Loading Dispatch Rider integration') module DispatchRider module Integrations module Appsignal def self.wrap_message(job, message) ::Appsignal.start ::Appsignal.monitor_transaction( 'perform_job.dispatch-rider', class: message.subject, method: 'handle', attempts: message.receive_count, queue: message.queue_name, queue_time: (Time.now.to_f - message.sent_at.to_f) * 1000, ) do job.call end ::Appsignal.stop end end end end DispatchRider.configure do |config| config.around(:dispatch_message) do |job, message| DispatchRider::Integrations::Appsignal.wrap_message(job, message) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dispatch-rider-2.1.0 | lib/dispatch-rider/integrations/appsignal.rb |
dispatch-rider-2.0.0 | lib/dispatch-rider/integrations/appsignal.rb |