2
0
mirror of https://github.com/hibiken/asynq.git synced 2024-12-26 07:42:17 +08:00

Delete "pending_since" under task-key when state changes to active

This commit is contained in:
Ken Hibino 2021-12-11 06:42:47 -08:00
parent 99a6750656
commit 22e6c9d297

View File

@ -232,6 +232,7 @@ if redis.call("EXISTS", KEYS[2]) == 0 then
if id then
local key = ARGV[2] .. id
redis.call("HSET", key, "state", "active")
redis.call("HDEL", key, "pending_since")
local data = redis.call("HMGET", key, "msg", "timeout", "deadline")
local msg = data[1]
local timeout = tonumber(data[2])