mirror of
https://github.com/hibiken/asynq.git
synced 2025-04-22 00:30:17 +08:00
Export (High|Low)PriorityQueue constant from base pkg
This commit is contained in:
parent
2e95166f39
commit
eb191c07d1
@ -13,6 +13,8 @@ const (
|
|||||||
failurePrefix = "asynq:failure:" // STRING - asynq:failure:<yyyy-mm-dd>
|
failurePrefix = "asynq:failure:" // STRING - asynq:failure:<yyyy-mm-dd>
|
||||||
queuePrefix = "asynq:queues:" // LIST - asynq:queues:<qname>
|
queuePrefix = "asynq:queues:" // LIST - asynq:queues:<qname>
|
||||||
DefaultQueue = queuePrefix + "default" // LIST
|
DefaultQueue = queuePrefix + "default" // LIST
|
||||||
|
HighPriorityQueue = queuePrefix + "high" // LIST
|
||||||
|
LowPriorityQueue = queuePrefix + "low" // LIST
|
||||||
ScheduledQueue = "asynq:scheduled" // ZSET
|
ScheduledQueue = "asynq:scheduled" // ZSET
|
||||||
RetryQueue = "asynq:retry" // ZSET
|
RetryQueue = "asynq:retry" // ZSET
|
||||||
DeadQueue = "asynq:dead" // ZSET
|
DeadQueue = "asynq:dead" // ZSET
|
||||||
|
@ -10,9 +10,9 @@ func TestQueueKey(t *testing.T) {
|
|||||||
p Priority
|
p Priority
|
||||||
want string
|
want string
|
||||||
}{
|
}{
|
||||||
{PriorityHigh, "asynq:queues:high"},
|
{PriorityHigh, HighPriorityQueue},
|
||||||
{PriorityDefault, "asynq:queues:default"},
|
{PriorityDefault, DefaultQueue},
|
||||||
{PriorityLow, "asynq:queues:low"},
|
{PriorityLow, LowPriorityQueue},
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, tc := range tests {
|
for _, tc := range tests {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user