Class: Bugsnag::Middleware::ActiveJob
- Inherits:
-
Object
- Object
- Bugsnag::Middleware::ActiveJob
- Defined in:
- lib/bugsnag/middleware/active_job.rb
Instance Method Summary collapse
- #call(report) ⇒ Object
-
#initialize(bugsnag) ⇒ ActiveJob
constructor
A new instance of ActiveJob.
Constructor Details
#initialize(bugsnag) ⇒ ActiveJob
Returns a new instance of ActiveJob.
3 4 5 |
# File 'lib/bugsnag/middleware/active_job.rb', line 3 def initialize(bugsnag) @bugsnag = bugsnag end |
Instance Method Details
#call(report) ⇒ Object
7 8 9 10 11 12 13 14 15 16 |
# File 'lib/bugsnag/middleware/active_job.rb', line 7 def call(report) data = report.request_data[:active_job] if data report.add_tab(:active_job, data) report.automatic_context = "#{data[:job_name]}@#{data[:queue]}" end @bugsnag.call(report) end |