Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 361259

Summary: "Automatically publish" produces ClassNotFoundException on JSP when resources change
Product: [WebTools] WTP ServerTools Reporter: anw <antoine.cardiweb>
Component: wst.serverAssignee: wst.server <wst.server-inbox>
Status: NEW --- QA Contact: Elson Yuen <eyuen7>
Severity: major    
Priority: P3 CC: brian
Version: unspecifiedKeywords: helpwanted
Target Milestone: Future   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Attachments:
Description Flags
Error trace none

Description anw CLA 2011-10-18 10:23:06 EDT
Build Identifier: 20110615-0604

Here in my company, we noticed a very annoying bug with Eclipse WTP server.
We can reproduce it on various Eclipse version (Helios, Indigo...) and for various environments (windows 7 and Linux).

The scenario to reproduce can be reproduced every time, but it is not the most annoying. The same symptoms appears randomly after server startup, while browsing web application, most of the time it will work correctly for the first hits but then it suddently breaks on a JSP.
It also occurs sometimes on the first hit to a server being IDLE for few minutes.

Any idea?

Reproducible: Always

Steps to Reproduce:
Here is how to reproduce it.
1. set up a Tomcat server in Eclipse (tested with Tomcat 6.0.32 and 7) with :
- Enabled "automatically publish when resources change"
- Disabled "Auto Reload" for my module

2. Start the server in debug mode
3. Before doing any hit to the server, modify a source from the deployed module (.java) (in example add a white space or a comment)
4. Wait a few seconds for getting changes deployed to the server, then do a hit to the server
5. This hit breaks whole web application and results in a ClassNotFoundException, the JSP class is not found, like if it were not compiled correctly. Only way is to restart server.
Here is the complete trace : http://pastebin.com/vNLEQrKH
Comment 1 anw CLA 2011-10-18 10:23:37 EDT
Created attachment 205422 [details]
Error trace
Comment 2 anw CLA 2011-10-18 10:28:10 EDT
Just for information, this problem looks related to server publishing option : "Automatically publish when resources change".
When using "Never publish automatically", it fixes the problem. 
But we have then to publish manually after modifying any resource.
Comment 3 Brian Gardner CLA 2014-11-30 22:30:38 EST
This is a duplicate of https://bugs.eclipse.org/bugs/show_bug.cgi?id=334977.  I've submitted a patch on that bug and am trying to get it reviewed and integrated