BURs: don't automatically retry failed BURs.

If a bulk update job fails, don't automatically retry it. Retrying it
will clobber the original error message if it fails again.
This commit is contained in:
evazion
2021-09-20 16:33:23 -05:00
parent 1d8a3bf09f
commit c6bf3e7934
3 changed files with 15 additions and 0 deletions

View File

@@ -5,6 +5,11 @@
class BigqueryExportJob < ApplicationJob
retry_on Exception, attempts: 0
# XXX delayed_job specific
def max_attempts
1
end
def perform(model:, **options)
BigqueryExportService.new(model, **options).export!
end

View File

@@ -3,6 +3,11 @@
class DiscordNotificationJob < ApplicationJob
retry_on Exception, attempts: 0
# XXX delayed_job specific
def max_attempts
1
end
def perform(forum_post:)
forum_post.send_discord_notification
end

View File

@@ -5,6 +5,11 @@
class ProcessBulkUpdateRequestJob < ApplicationJob
retry_on Exception, attempts: 0
# XXX delayed_job specific
def max_attempts
1
end
def perform(bulk_update_request)
bulk_update_request.processor.process!
end