Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set Sidekiq retries to 3 even for ActionMailer::MailDeliveryJob #144

Merged
merged 1 commit into from
Jan 10, 2024

Commits on Jan 10, 2024

  1. Set Sidekiq retries to 3 even for ActionMailer::MailDeliveryJob

    `ActionMailer::MailDeliveryJob` inherits from `ActiveJob::Base` [1]; not
    from `ApplicationJob`. I suspect that's why the retry option in
    `ApplicationJob` didn't seem to be having any effect on jobs created by
    sending an email.
    
    It's hard to get a definitive answer, but I'm fairly confident setting
    the `retry` option on `Sidekiq.default_job_options` should apply
    globally to all jobs sent to Sidekiq, i.e. including
    `ActionMailer::MailDeliveryJob`.
    
    Fixes #143 (hopefully!🤞)
    
    [1]: https://github.com/rails/rails/blob/23938052acd773fa24068debe56cd892cbf8d868/actionmailer/lib/action_mailer/mail_delivery_job.rb#L13
    floehopper committed Jan 10, 2024
    Configuration menu
    Copy the full SHA
    2f0adb0 View commit details
    Browse the repository at this point in the history