开发者

Tomcat Auto Deploy Feature is this good?

I downloaded and setup my Apache Tomcat 6 in our production server. I then started it to see if it's running, and found out that its okay.

It runs and then I place my project war file there. I am about to restart the tomcat service when I notice that that my web archive file was already unzipped and my project web file is already set at the web apps folder.

I think, my setup has an auto-deploy feature but I kept on thinking if this is a good thing?

I have these questions in mind:

  1. Does Tomcat really auto deploys web archive file and what is the frequency that it does?
  2. Is this a nice feature?
  3. So what if I leave my war file there, does that mean that Tomcat will reload or unzip the a开发者_JAVA技巧rchive file every now and then?
  4. Is what Tomcat does to my war file the same as when I properly restart my tomcat and let the tomcat service deploy my war file?


Have a look at the manual. It says:

If the Host autoDeploy attribute is "true", the Host will attempt to deploy and update web applications dynamically, as needed, for example if a new .WAR is dropped into the appBase

Whether this is a nice feature depends on your requirements. None of the projects I worked on needed this, but hey - your story might be different.

Autodeploy is the same feature as if you would restart Tomcat and it would find a .war sitting around, the only difference is that there has to be a polling thread which looks for changes in the appBase folder.


Be careful when using this autoDeploy feature. It will first 'undeploy' the application if an existing version exists and it will delete the context configuration file as well ($CATALINA_HOME/conf/[engine-name]/[host-name]/[app-name].xml).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜