Module: Appsignal::Integrations::ResqueIntegration Private
- Defined in:
- lib/appsignal/integrations/resque.rb
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Instance Method Summary collapse
- #perform ⇒ Object private
Instance Method Details
#perform ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/appsignal/integrations/resque.rb', line 7 def perform transaction = Appsignal::Transaction.create( SecureRandom.uuid, Appsignal::Transaction::BACKGROUND_JOB, Appsignal::Transaction::GenericRequest.new({}) ) Appsignal.instrument "perform.resque" do super end rescue Exception => exception # rubocop:disable Lint/RescueException transaction.set_error(exception) raise exception ensure if transaction transaction.set_action_if_nil("#{payload["class"]}#perform") args = Appsignal::Utils::HashSanitizer.sanitize( ResqueHelpers.arguments(payload), Appsignal.config[:filter_parameters] ) transaction.params = args if args transaction.("queue" => queue) Appsignal::Transaction.complete_current! end Appsignal.stop("resque") end |