maintenance: break maintenance tasks into individual jobs.
Break the hourly/daily/weekly/monthly maintenance tasks down into individual delayed jobs. This way if one task fails, it won't prevent other tasks from running. Also, jobs can be run in parallel, and can be individually retried if they fail.
This commit is contained in:
7
app/jobs/dmail_inactive_approvers_job.rb
Normal file
7
app/jobs/dmail_inactive_approvers_job.rb
Normal file
@@ -0,0 +1,7 @@
|
||||
# A job that runs weekly to warn inactive approvers before they're demoted.
|
||||
# Spawned by {DanbooruMaintenance}.
|
||||
class DmailInactiveApproversJob < ApplicationJob
|
||||
def perform
|
||||
ApproverPruner.dmail_inactive_approvers!
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user