Skip to content

Commit

Permalink
Retry text delivery server errors
Browse files Browse the repository at this point in the history
If the text could not be delivered due to a server error, i.e. an issue
with GOV.UK Notify, then we should keep trying to send these to avoid
needing to manually re-send them via the Good Job dashboard.
  • Loading branch information
thomasleese committed Jan 15, 2025
1 parent eb60cbb commit b5b19be
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/jobs/notify_delivery_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
class NotifyDeliveryJob < ApplicationJob
queue_as { Rails.configuration.action_mailer.deliver_later_queue_name }

retry_on Notifications::Client::ServerError, wait: :polynomially_longer

def self.client
@client ||=
Notifications::Client.new(
Expand Down

0 comments on commit b5b19be

Please sign in to comment.