Supervisor / supervisor

Supervisor process control system for Unix (supervisord)
http://supervisord.org
Other
8.47k stars 1.25k forks source link

Add the ability to set different "restart policies" on process workers #456

Open castarco opened 10 years ago

castarco commented 10 years ago

At this time, the do_restart method in supervisorctl does a do_stop and then a do_start. If we have many workers for a process group, it would be nice to add the possibility to restart every worker in a sequential way, one worker after another worker (to easily achieve zero downtime).

In my case, I have one worker per CPU, and I'm using a local HAProxy to "simulate" a single server.

I'd like to read the main developer's opinion. If they don't want to do it I'll be grateful to receive advice to contribute with my code... and if it's "impossible", i'll be gratefull to be informed about ^^U .

Thanks in advance!

mcdonc commented 10 years ago

While I'll keep this issue open to investigate whether we should change supervisorctl, note that it's totally possible (and even encouraged really) to write a custom XML-RPC client that serially starts and stops some number of processes.

See http://supervisord.org/api.html

backbord commented 9 years ago

I would love to see this feature in supervisor and be able to configure the restart policy per process group.