Using RQ for a while, stale data can get piled up in Redis. Most notably dead workers and a full failed
queue.
We should provide a simple means of discarding that data on the command line.
Best place I can think of for that now is rqinfo --clear
of some sort. Open for discussion/tips.
I have a need for the same thing... Does something like this work?
from redis import Redis
from rq import Queue
from rq import Worker
q = Queue(connection=Redis())
low = Queue('low',connection=Redis())
failed = Queue('failed',connection=Redis())
q.empty()
low.empty()
failed.empty()
for w in Worker.all(connection=Redis()):
print w.register_death()
Would a command such as rqinfo --clear
also remove queues?
+1 for this!
Most helpful comment
I have a need for the same thing... Does something like this work?