views:

15

answers:

0

Hi everyone,

We have a Tomcat cluster with two instances (version 5.5.25) running on a single machine. We use this to make sure our web page is available and that all sessions survive during redeployment.

We were wondering if sessions could be lost during this procedure. Here is what we do:
a) Application is running on tomcatA and tomcatB and all sessions are replicated
b) Application on tomcatA is undeployed, all requests are redirected to tomcatB
c) Application on tomcatA is deployed
* Now the cluster needs to make sure that all sessions are replicated properly on tomcatA
d) Application on tomcatB is undeployed, all requests are redirected to tomcatA
e) Application on tomcatB is deployed

We use an ant script and the tomcat manager tasks to control the deployment procedure. Note that we are not actually bringing down any tomcat instances, but rather we're just redeploying a particular application while the rest are still running.

  1. Could sessions be lost in this procedure when the undeployment of the webapp on tomcatB happens right after the deployment on tomcatA?
  2. Does the tomcat manager deploy task in step (c) only return once all sessions are successfully replicated?
  3. If not is there a way to ensure all sessions are replicated before undeploying the webapp on tomcatB?

Thanks, Mitko