How do I clear stuck/stale Resque workers?

后端 未结 15 771
你的背包
你的背包 2020-12-07 07:22

As you can see from the attached image, I\'ve got a couple of workers that seem to be stuck. Those processes shouldn\'t take longer than a couple of seconds.

15条回答
  •  暖寄归人
    2020-12-07 07:39

    I just did:

    % rails c production
    irb(main):001:0>Resque.workers
    

    Got the list of workers.

    irb(main):002:0>Resque.remove_worker(Resque.workers[n].id)
    

    ... where n is the zero based index of the unwanted worker.

提交回复
热议问题