tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Caldarale, Charles R" <Chuck.Caldar...@unisys.com>
Subject RE: tomcat 6.0.20 different instances with diff ips but same port no 80
Date Tue, 01 Sep 2009 15:32:08 GMT
> From: Michael Ludwig [mailto:mlu@as-guides.com]
> Subject: Re: tomcat 6.0.20 different instances with diff ips but same
> port no 80
> 
> A server may have mulitple <Service> elements. Don't ask me why you'd
> want more than one <Service> elements [2] - because that's what I'd
> like to ask the experts. Anyone?

Seemed like a good idea at the time?  If you look inside Tomcat, you'll see that it's a set
of nested containers, with <Server> being the top one, and <Service> the next
layer.  You might want to use multiple <Service> elements if you want to run a single
JVM with independent servlet engines inside (think embedded controller, where the number of
processes is limited).

> (1) By dropping a copy in each of the different Host/@appBase?

This is probably the best, since it allows independent updating of the .war file for each
<Host>.

> (2) By having all three Host/@appBase point to the same location
>      (and then of course put the WAR there)?

This appears to work, but each <Host> will be monitoring the same locations for changes
(assuming autoDeploy is true), and there might be some timing issues.

> (3) By some other means?

By placing a second_world.xml file in each of the conf/Catalina/[host] directories, with the
<Context> element therein having a docBase attribute pointing to the actual location
of the .war file.  This is pretty much equivalent to #2, except you can tailor the <Context>
element for each <Host>, if needed.

Regardless, your webapp will be deployed once for each <Host>.  If you don't want that,
just use a single <Host>, and let it field requests for all of alpha, beta, and gamma.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus
for use only by the intended recipient. If you received this in error, please contact the
sender and delete the e-mail and its attachments from all computers.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message