0
0
Fork 0

Preheat status cache

This commit is contained in:
Eugen Rochko 2017-02-05 17:24:18 +01:00
parent 6fa4e01139
commit 19b9e1e2c3
4 changed files with 16 additions and 4 deletions

View file

@ -4,7 +4,10 @@ class DistributionWorker
include Sidekiq::Worker
def perform(status_id)
FanOutOnWriteService.new.call(Status.find(status_id))
status = Status.find(status_id)
FanOutOnWriteService.new.call(status)
WarmCacheService.new.call(status)
rescue ActiveRecord::RecordNotFound
true
end