Skip to content

Commit

Permalink
Add retry_on/discard suggestions for common cases.
Browse files Browse the repository at this point in the history
This adds the same suggestions added here:
https://github.com/rails/rails/blob/01a69e27a4e55504af8fe776826d659550e6f89e/activejob/lib/rails/generators/job/templates/application_job.rb

These appear when `app/jobs/application_job.rb` doesn't exist, but not
for new applications.
  • Loading branch information
frodsan committed Oct 5, 2018
1 parent 9422433 commit 1040893
Showing 1 changed file with 5 additions and 0 deletions.
@@ -1,2 +1,7 @@
class ApplicationJob < ActiveJob::Base
# Automatically retry jobs that encountered a deadlock
# retry_on ActiveRecord::Deadlocked

# Most jobs are safe to ignore if the underlying records are no longer available
# discard_on ActiveJob::DeserializationError
end

0 comments on commit 1040893

Please sign in to comment.