Module: SidekiqSolidFetch::Throttled::StrategyPatch

Defined in:
lib/sidekiq_solid_fetch/throttled.rb

Instance Method Summary collapse

Instance Method Details

#re_enqueue_throttled(work, target_queue) ⇒ Object



26
27
28
29
30
31
# File 'lib/sidekiq_solid_fetch/throttled.rb', line 26

def re_enqueue_throttled(work, target_queue)
  return super unless work.is_a?(::SidekiqSolidFetch::UnitOfWork)

  target_queue = "queue:#{target_queue}" unless target_queue.start_with?("queue:")
  work.requeue_throttled(target_queue)
end