Multiple resque workers mode creating extra processes

孤人 提交于 2019-12-03 07:55:01
Winfield

You don't want to use the COUNT=n option in production, as it runs each worker in a thread instead of a separate process - which is much less stable.

Official Resque docs:

Running Multiple Workers

At GitHub we use god to start and stop multiple workers. A sample god configuration file is included under examples/god. We recommend this method.

If you'd like to run multiple workers in development mode, you can do so using the resque:workers rake task:

$ COUNT=5 QUEUE=* rake resque:workers
This will spawn five Resque workers, each in its own thread. Hitting ctrl-c should be sufficient to stop them all.

Here's the example God monitoring/configuration file that ships with Resque to run multiple processes, and here's an example for monit.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!