[Sidekiq] Enqueue the previously added jobs

This commit is contained in:
Earlopain 2023-05-01 16:42:21 +02:00
parent a33077b983
commit c4e33651c6
No known key found for this signature in database
GPG Key ID: 6CFB948E15246897
5 changed files with 6 additions and 6 deletions

View File

@ -29,7 +29,7 @@ module Indexable
if defer
if priority == :high
IndexUpdateJob.perform_async(self.class.to_s, id)
IndexUpdateJobCopy.perform_later(self.class.to_s, id)
elsif priority == :rebuild
IndexRebuildJob.perform_later(self.class.to_s, id)
else

View File

@ -215,9 +215,9 @@ class Post < ApplicationRecord
def generate_video_samples(later: false)
if later
PostVideoConversionJob.perform_in(1.minute, self.id)
PostVideoConversionJobCopy.set(wait: 1.minute).perform_later(id)
else
PostVideoConversionJob.perform_async(self.id)
PostVideoConversionJobCopy.perform_later(id)
end
end

View File

@ -11,7 +11,7 @@ class TagAlias < TagRelationship
CurrentUser.scoped(approver) do
update(status: "queued", approver_id: approver.id)
create_undo_information
TagAliasJob.perform_async(id, update_topic)
TagAliasJobCopy.perform_later(id, update_topic)
end
end

View File

@ -166,7 +166,7 @@ class TagImplication < TagRelationship
update(status: "queued", approver_id: approver.id)
create_undo_information
invalidate_cached_descendants
TagImplicationJob.perform_async(id, update_topic)
TagImplicationJobCopy.perform_later(id, update_topic)
end
def reject!(update_topic: true)

View File

@ -200,7 +200,7 @@ class Takedown < ApplicationRecord
end
def process!(approver, del_reason)
TakedownJob.perform_async(id, approver.id, del_reason)
TakedownJobCopy.perform_later(id, approver.id, del_reason)
end
end