1
0
Fork 0
mirror of https://github.com/mperham/sidekiq.git synced 2022-11-09 13:52:34 -05:00

Push to front of queue, not back

This commit is contained in:
Mike Perham 2013-01-16 13:08:10 -08:00
parent 53862bda36
commit 742aeaa90e

View file

@ -125,7 +125,7 @@ module Sidekiq
# we'll use the object_id to track the worker's data here.
processor.terminate if processor.alive?
unit_of_work = @in_progress[processor.object_id]
conn.lpush(unit_of_work.queue, unit_of_work.message)
conn.rpush(unit_of_work.queue, unit_of_work.message)
end
end
logger.info("Pushed #{@busy.size} messages back to Redis")