diff options
author | Arthur Nogueira Neves <github@arthurnn.com> | 2015-10-04 20:38:44 -0400 |
---|---|---|
committer | Arthur Nogueira Neves <github@arthurnn.com> | 2015-10-04 20:38:44 -0400 |
commit | d2ef471b849b28c6962e4ed784fbec42aae9f9ec (patch) | |
tree | 7debce7279744cfec10a0bff2140d52bc97422ae /activejob | |
parent | 411ed2086546f0331ce57f734efe41d37ad16b0a (diff) | |
parent | 30b640045f0a35ebf76a37956b75dd4aa04d475f (diff) | |
download | rails-d2ef471b849b28c6962e4ed784fbec42aae9f9ec.tar.gz rails-d2ef471b849b28c6962e4ed784fbec42aae9f9ec.tar.bz2 rails-d2ef471b849b28c6962e4ed784fbec42aae9f9ec.zip |
Merge pull request #20116 from cristianbica/activejob-enqueue-logging
ActiveJob - log enqueued message only after the job was successfully enqueued
Diffstat (limited to 'activejob')
-rw-r--r-- | activejob/lib/active_job/logging.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activejob/lib/active_job/logging.rb b/activejob/lib/active_job/logging.rb index d72e1bdfce..605057d1e8 100644 --- a/activejob/lib/active_job/logging.rb +++ b/activejob/lib/active_job/logging.rb @@ -26,7 +26,7 @@ module ActiveJob end end - before_enqueue do |job| + after_enqueue do |job| if job.scheduled_at ActiveSupport::Notifications.instrument "enqueue_at.active_job", adapter: job.class.queue_adapter, job: job |