distribute tag subscription processor over 20 hours
This commit is contained in:
@@ -182,7 +182,7 @@ class TagSubscription < ActiveRecord::Base
|
||||
def self.process_all
|
||||
find_each do |tag_subscription|
|
||||
if tag_subscription.is_active?
|
||||
time = rand(4 * 60 * 60).seconds.from_now
|
||||
time = rand(20 * 60 * 60).seconds.from_now
|
||||
TagSubscription.delay(:run_at => time, :queue => "default", :priority => 10).process(tag_subscription.id)
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user