scrapix
scrapix copied to clipboard
Add route to empty the task queue
Sometimes it might be useful to cancel the tasks queue. It happened when I send the wrong meilisearch credentials but the processes were already launched.
This is the way to do it:
this.queue = new Queue("crawling", redis_url);
this.queue.obliterate({ force: true });
Damn, they know how to name a method; "obliterate" :rage4: