1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activejob/test/cases
Jonathan Rochkind dcce260edc Add job_id and exception message to ActiveJob retry/discard logging
In other log messages like perform/performed and ActiveJob error logging, the job ID and exception message were already included, eg:

    Error performing TestFailureJob (Job ID: d70ad13e-e58b-409c-a8cc-e0447fc792b5) from Resque(default) in 1446.56ms: RuntimeError (Error Message):

But log message related to retry/discard behavior from ActiveJob::Exceptions did not include the Job ID or exception message. We now include them, in a consistent format with other existing messages.

Job ID is especially useful because, while other ActiveJob-related log messages get the Job ID via tagged logging, retry-related log messages do not currently end up tagged with Job ID. And it's really useful to use Job ID to be able to collect all the log lines related to a particular job, put the error messages together with the retry and subsequent perform messages.

We also include job.executions in the enqueue_retry log message because it was available and useful, to know if this is the 1st retry or 2nd or whatever. Previously job.executions was included in retry_stopped logging, but not enqueue_retry.
2022-02-08 10:06:21 -05:00
..
adapter_test.rb
argument_serialization_test.rb Raise error when serializing an anonymous class. 2021-10-13 11:55:23 -04:00
callbacks_test.rb Removed deprecated behavior that was not halting after_enqueue/after_perform callbacks when a previous callback was halted with throw :abort. 2021-11-17 21:51:17 +00:00
delayed_job_adapter_test.rb Avoid logging delayed job arguments if log_arguments set to false 2021-08-01 21:46:44 +01:00
exceptions_test.rb Tweak unreachable assertion tests in the block of assert_raises 2021-08-17 20:33:08 +09:00
job_serialization_test.rb Fix random CI fail due to auto-updating timestamp 2020-04-06 23:31:29 -05:00
logging_test.rb Add job_id and exception message to ActiveJob retry/discard logging 2022-02-08 10:06:21 -05:00
queue_adapter_test.rb Fix queue adapter class delegation to point to self.class 2019-09-23 21:59:59 -03:00
queue_naming_test.rb Allow ActiveJob::Base.set to configure job when using .perform_now 2021-10-12 13:53:38 -07:00
queue_priority_test.rb Allow ActiveJob::Base.set to configure job when using .perform_now 2021-10-12 13:53:38 -07:00
queuing_test.rb Communicate enqueue failures to callers of perform_later 2021-02-05 16:32:43 -05:00
rescue_test.rb Allow jobs to rescue all exceptions 2021-01-23 08:35:51 -05:00
serializers_test.rb Enable Layout/EmptyLinesAroundAccessModifier cop 2019-06-13 12:00:45 +09:00
test_case_test.rb
test_helper_test.rb Merge PR #43066 2022-01-06 16:53:31 +00:00
timezones_test.rb Reset Time.zone to avoid leaking into other tests 2020-11-15 01:02:22 +00:00
translation_test.rb