Files
boc/vims-backend/node_modules/bull/lib/commands/pause-5.lua
T
Bernt 6de2455917 v1.2.0: Add Global Markets footer, translated to 9 languages
- Added GLOBAL_MARKETS_TITLE to all translation files
- Updated footer with 12 markets (4 active + 8 upcoming)
- Translated market section to: zh-cn, zh-tw, ja, ko, th, vi, id, ms, hi
- Built and deployed to production
- CloudFront invalidation: I3RTMXVFDJXWLG3SYX208OP1CC
2026-07-08 19:56:03 +00:00

36 lines
715 B
Lua

--[[
Pauses or resumes a queue globably.
Input:
KEYS[1] 'wait' or 'paused''
KEYS[2] 'paused' or 'wait'
KEYS[3] 'meta-paused'
KEYS[4] 'paused' o 'resumed' event.
KEYS[5] 'meta' this key is only used in BullMQ and above.
ARGV[1] 'paused' or 'resumed'
Event:
publish paused or resumed event.
]]
local rcall = redis.call
if rcall("EXISTS", KEYS[1]) == 1 then
rcall("RENAME", KEYS[1], KEYS[2])
end
if ARGV[1] == "paused" then
rcall("SET", KEYS[3], 1)
-- for forwards compatibility
rcall("HSET", KEYS[5], "paused", 1)
else
rcall("DEL", KEYS[3])
-- for forwards compatibility
rcall("HDEL", KEYS[5], "paused")
end
rcall("PUBLISH", KEYS[4], ARGV[1])