circus-tent / circus

A Process & Socket Manager built with zmq
http://circus.readthedocs.org/
Other
1.55k stars 258 forks source link

Serial restart for a watcher's processes #742

Open lucian1900 opened 10 years ago

lucian1900 commented 10 years ago

It would be great if I could tell circusd to restart one process at a time within a watcher and not kill them all in parallel and then restart them all in parallel. For now, I'm working around this by parsing circusctl stats watchername and killing the processes one by one, expecting circusd to restart them.

The motivation for this is using circusd for a project which has:

I love that circusd lets me restart even the HTTP workers without downtime, but it would be nice to not have "slowtime" either, where during a watcher restart clients wait on a new worker coming up.

Natim commented 10 years ago

Hello, there is something in salt that lets you choose the batch-size (http://docs.saltstack.com/topics/targeting/batch.html) we could integrate something like that to the restart command.

lucian1900 commented 10 years ago

Yeah, circusctl restart --batch=1 would be equivalent to my workaround. I would probably also call it through the API, which I assume Salt would be doing as well.

tarekziade commented 10 years ago

:+1:

pomarec commented 10 years ago

Shoud you close this issue ?

mitsuhiko commented 9 years ago

Why was this closed?

pomarec commented 9 years ago

I don't even remember why I was interested in this topic.

k4nar commented 9 years ago

I don't know, I don't see any similar option in Circus. I guess it would not hard to do something like salt, with --batch=1 or --batch=25%.