I followed the following steps
I found that when i restarted Tomcat, the existing files in the folder that was expanded previously were not updated. Shouldnt the update to the war file have updated the relevant jsp, class file?
I looked at the documentation and found this http://tomcat.apache.org/tomcat-5.5-doc/config/host.html. The following quote under "Automatic Application Deployment"
In addition to the automatic deployment that occurs at startup time, you can also request that new XML configuration files, WAR files, or subdirectories that are dropped in to the appBase (or
$CATALINA_HOME/conf/[engine_name]/[host_name] in the case of an XML configuration file) directory while Tomcat is running will be automatically deployed, according to the rules described above. The auto deployer will also track web applications for the following changes:
- An update to the WEB-INF/web.xml file will trigger a reload of the web application
- An update to a WAR which has been expanded will trigger an undeploy (with a removal of the expanded webapp), followed by a deployment
- An update to a XML configuration file will trigger an undeploy (without the removal of any expanded directory), followed by a deployment of the associated web application
Shouldnt the files have been automatically been updated as a result of point 2 above?
Autodeploy is set to true in server.xml
Historically, tomcat has never updated the exploded directory when you just drop in a new jar, at least for me. I always assumed this to be a bug, but never looked into it as there is a simple solution. Both of these should work fine: