1

I've this unique scenario :

Say I've some jsp file (a.jsp) and tomcat is serving this page. Suppose i now delete the file a.jsp and add again a.jsp (with little modifications) the tomcat is not taking the newly modified file. It says file is missing even though the file is there at exactly the same location. Otherwise i've to refresh the project in eclipse for the changes to take effect.

I tried adding the following block in tomcat's web.xml but it didn't help much:

<init-param>
  <param-name>checkInterval</param-name>
  <param-value>1</param-value>
</init-param>

I'd like to know if there is any solution where i don't need to refresh the project and the changes are taken in seamlessly.

The issue here is if i edit the same jsp (it still works fine -- the changes take in effect) but if i delete the jsp file and then add the same jsp file (at the same location) with little modifications the changes does not take in effect

manohar_tn
  • 101
  • 1
  • 10

2 Answers2

0

Did you enable Hot-Deploy? If you double-click Tomcat in Eclipse there should be a Publishing-Section. "Publish on Save" is probably disabled. Take a look at following Question it could be related to your problem: Integrating tomcat and eclipse as a hot-deploy environment

Community
  • 1
  • 1
ChrisKo
  • 365
  • 2
  • 8
  • Yes, the option "Automatically publish when resources change" is enabled The issue is if i edit the same jsp (it still works fine -- the changes take in effect) but if i delete the jsp file and then add the same jsp file with little modifications the changes does not take in effect – manohar_tn Jul 29 '15 at 20:26
0

At some point, another request must have come-in for a.jsp and Tomcat has cached the "not found" result. There have been a bunch of reports of Tomcat caching responses longer than expected, and I haven't gotten a clear answer for why that happens. It usually ends up being some slightly wrong configuration.

Christopher Schultz
  • 20,221
  • 9
  • 60
  • 77