tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Ludwig <>
Subject Re: tomcat 6.0.20 different instances with diff ips but same port no 80
Date Tue, 01 Sep 2009 15:59:54 GMT
Caldarale, Charles R schrieb:
>> From: Michael Ludwig []
>> 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).

Thanks, that sufficiently clarifies it.

>> (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.

A detail that adds flexibility and makes a difference.

In practice, I would probably deploy the app, grab the extracted
second_world.xml, put it under version control (I know admins don't
use that, but I would), make my changes, commit them, and then place
a copy in each of the aforementioned directories so it prevents the
original from the WAR to be extracted and used. Does that sound like
solid operating procedure? :-)

> 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.

Just to be sure, would I do that by using:

<Home name="alpha" ...>

Michael Ludwig

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message