You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Leo Donahue - PLANDEVX <Le...@mail.maricopa.gov> on 2011/11/07 22:52:28 UTC

Deploying .war files

Tomcat 6.0.32

When you add a new .war file to the webapps directory (by dragging the file in there from another directory)  and it automatically expands the web archive, is that any different than what the manager application does when it deploys the .war file?

Likewise when you delete the .war file from the webapps directory, the expanded web archive will shortly remove itself as well.

Is there some amount of time that is required if you want to redeploy the same .war file you just removed/undeployed with a newer version (same name)?  I can't get a consistent response from either physically adding the .war file to the web apps directory and then deleting it/replacing it with a newer version of the .war file, or whether I use the manager application to deploy/undeploy/deploy.

It seems as if I try to redeploy the newer version of the war file I just deleted too soon everything hangs and while the newer .war file will expand, it gives a 404 response when I access that web app. If I wait about 30 or 40 seconds between undeploying the old and redeploying the new it works although I didn't actually record the time in between.

Leo


Re: Deploying .war files

Posted by ma...@apache.org.
Leo Donahue - PLANDEVX <Le...@mail.maricopa.gov> wrote:

>Tomcat 6.0.32
>
>When you add a new .war file to the webapps directory (by dragging the
>file in there from another directory)  and it automaticallyp expands the
>web archive, is that any different than what the manager application
>does when it deploys the .war file?

Yes. The manager ensures that the war is fully copied. Manual copy has some tricks to try and ensure this but can't guarantee it.

>Likewise when you delete the .war file from the webapps directory, the
>expanded web archive will shortly remove itself as well.
>
>Is there some amount of time that is required if you want to redeploy
>the same .war file you just removed/undeployed with a newer version
>(same name)?  I can't get a consistent response from either physically
>adding the .war file to the web apps directory and then deleting
>it/replacing it with a newer version of the .war file, or whether I use
>the manager application to deploy/undeploy/deploy.

Better to just overwrite the old war with the new one. Tomcat will handle the rest.

>It seems as if I try to redeploy the newer version of the war file I
>just deleted too soon everything hangs and while the newer .war file
>will expand, it gives a 404 response when I access that web app. If I
>wait about 30 or 40 seconds between undeploying the old and redeploying
>the new it works although I didn't actually record the time in between.

The check for deleted / new wars runs once every 15s.

Mark





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