Tony Collen wrote:
Bertrand Delacretaz wrote:
Le 2 juin 04, à 16:52, Upayavira a écrit :
...And also, using Apache's cool 'graceful' restart feature, I can upgrade a client from v1.1 webapp to v1.2 webapp without any downtime at all...
You've tickled my curiosity here, can you elaborate or point me to relevant docs about this feature?
The 'apachectl' command has a "graceful" parameter:
graceful - do a graceful restart by sending a SIGUSR1 or start if not running
Basically, any requests that are currently being handled will continue, and when the child server process finishes, it will refresh. Otherwise, if someone has a transfer going (like a big download), the download will just stop if you do 'apachectl restart'.
Aw. You spoilsport ;-) I was hoping to tell him that!
I've got a configuration script that creates an httpd.conf file containing rewrite rules. I use a rewrite map to map client names to versions, so www.mysite.com/clientA is rewritten to www.v1.1.mysite.com/clientA, whereas www.mysite.com/clientB is rewritten to www.v1.2.mysite.com/clientB. I have added those two new domain names to my /etc/hosts file (actually, my script does that), and then have Jetty mount two webapps, one against each domain. (It is actually even cleverer than that, as it also handles load balancing while it is at it).
I now edit a config file, and run a script. The script buiilds the httpd.conf, the jetty config, the rewrite maps, and the /etc/hosts files, and then does a graceful Apache restart.
The results of numerous overnight hard work (so I could break our Uk based server without troubling our userbase). And I'm chuffed with it.
Anyway, note that I couldn't find this on Windows, but it is available on Unix.
Regards, Upayavira
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]