1

I am about to implement load balancing with apache webserver and two tomcat servers.

The war deployed on both tomcats has common resources like images and css folders, which are quietly large, so if some change happens in image i have to do a copy and past again in the other war file deployed.

I am looking out to try to map a fix directory for both the war files that will fetch from common folder. (i.e Tomcat 1 and Tomcat 2 will access css folder from C:\css\ same for images )

I tried writing servlet that deployed images but that was not feasible.

Any other way to work around for high availability for resource serving ?

Please Assist if you have any idea.

4

1 回答 1

0

我知道我们可以在 server.xml 中为 tomcat 映射一个外部目录

<Host name="localhost"  appBase="webapps" unpackWARs="true" autoDeploy="true">
//ADD THIS TO THE HOST TAG
<Context path="/content" docBase="E:/Atul/data/" />

</Host>
于 2013-08-27T10:40:05.667 回答