diff --git a/lib/sidekiq/fetch.rb b/lib/sidekiq/fetch.rb index 44d7587e..3f0b6c70 100644 --- a/lib/sidekiq/fetch.rb +++ b/lib/sidekiq/fetch.rb @@ -116,8 +116,10 @@ module Sidekiq end Sidekiq.redis do |conn| - jobs_to_requeue.each do |queue, jobs| - conn.rpush("queue:#{queue}", jobs) + conn.pipelined do + jobs_to_requeue.each do |queue, jobs| + conn.rpush("queue:#{queue}", jobs) + end end end Sidekiq.logger.info("Pushed #{inprogress.size} messages back to Redis")