Reset to highest priority next queue strategy ignores delayed tasks
dvizelman opened this issue · comments
Dima Vizelman commented
When workers are defined to use RESET_TO_HIGHEST_PRIORITY next queue strategy, they are suddenly stop to recognize delayed tasks and execute all the tasks as immediate tasks
Dima Vizelman commented
I've checked the issue and it appears that issue can be easily fixed by introducing small changes in WorkerImpl.java and workerScripts/fromMultiplePriorityQueues.lua:
WorkerImpl.java , pop():
add Long.toString(System.currentTimeMillis() parameter to evalsha
workerScripts/fromMultiplePriorityQueues.lua:
local now = ARGV[1]
local firstMsg = redis.call('ZRANGEBYSCORE', queueName, '-inf', now, 'WITHSCORES', 'LIMIT' , '0' , '1')
Greg Haines commented
PRs are welcome!