Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 174352 - HTTP 500 error in Web Services Explorer
Summary: HTTP 500 error in Web Services Explorer
Status: CLOSED FIXED
Alias: None
Product: WTP Webservices
Classification: WebTools
Component: wst.ws (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows XP
: P3 critical (vote)
Target Milestone: 2.0 M6   Edit
Assignee: Andrew Mak CLA
QA Contact: Chris Brealey CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-02-15 13:33 EST by Mark Hutchinson CLA
Modified: 2007-04-03 15:34 EDT (History)
3 users (show)

See Also:


Attachments
catalina log (15.77 KB, text/plain)
2007-03-22 15:46 EDT, Mark Hutchinson CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Hutchinson CLA 2007-02-15 13:33:01 EST
Build ID: I-I200702150450

Steps To Reproduce:
1. Start eclipse version I-I200702150450.
2. Select Run > Web Services Explorer
3. Observe the HTTP 500 error 


More information:
In the catalina log i see:
WebappLoader[]: Deploying class repositories to work directory D:\wtp\0215-2.0\eclipse\smoketestworkspace\.metadata\.plugins\org.eclipse.tomcat\ROOT
ContextConfig[]: Added certificates -> request attribute Valve
StandardManager[]: Seeding random number generator class java.security.SecureRandom
StandardManager[]: Seeding of random number generator has been completed
StandardWrapper[:default]: Loading container servlet default
StandardWrapper[:invoker]: Loading container servlet invoker
CoyoteConnector Coyote can't register jmx for protocol
WebappLoader[/wsexplorer]: Deploying class repositories to work directory D:\wtp\0215-2.0\eclipse\smoketestworkspace\.metadata\.plugins\org.eclipse.tomcat\wsexplorer
WebappLoader[/wsexplorer]: Deploy class files /WEB-INF/classes to D:\wtp\0215-2.0\eclipse\smoketestworkspace\.metadata\.plugins\org.eclipse.tomcat\wsexplorer\WEB-INF\classes
WebappLoader[/wsexplorer]: Deploy JAR /WEB-INF/lib/wsexplorer.jar to D:\wtp\0215-2.0\eclipse\smoketestworkspace\.metadata\.plugins\org.eclipse.tomcat\wsexplorer\WEB-INF\lib\wsexplorer.jar
ContextConfig[/wsexplorer]: Added certificates -> request attribute Valve
StandardManager[/wsexplorer]: Seeding random number generator class java.security.SecureRandom
StandardManager[/wsexplorer]: Seeding of random number generator has been completed
StandardWrapper[/wsexplorer:default]: Loading container servlet default
StandardWrapper[/wsexplorer:invoker]: Loading container servlet invoker
StandardWrapperValve[wsexplorer_jsp]: Servlet.service() for servlet wsexplorer_jsp threw exception
javax.servlet.ServletException: org.apache.jasper.runtime.JspRuntimeLibrary.include(Ljavax/servlet/ServletRequest;Ljavax/servlet/ServletResponse;Ljava/lang/String;Ljavax/servlet/jsp/JspWriter;Z)V
	at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:536)
	at wsexplorer_jsp._jspService(Unknown Source)
	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
	at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2422)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
	at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
	at org.eclipse.tomcat.internal.EclipseErrorReportValve.invoke(EclipseErrorReportValve.java:153)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:199)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:828)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:700)
	at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:584)
	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
	at java.lang.Thread.run(Unknown Source)
----- Root Cause -----
java.lang.NoSuchMethodError: org.apache.jasper.runtime.JspRuntimeLibrary.include(Ljavax/servlet/ServletRequest;Ljavax/servlet/ServletResponse;Ljava/lang/String;Ljavax/servlet/jsp/JspWriter;Z)V
	at wsexplorer_jsp._jspService(Unknown Source)
	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
	at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2422)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
	at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
	at org.eclipse.tomcat.internal.EclipseErrorReportValve.invoke(EclipseErrorReportValve.java:153)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
	at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:199)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:828)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:700)
	at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:584)
	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
	at java.lang.Thread.run(Unknown Source)
Comment 1 Chris Brealey CLA 2007-02-16 09:25:02 EST
Gil, please investigate. M4 and M5 have the Tomcat plugin with the same jasper-runtime.jar, so the problem may be related to the WSE build's JspC/javac tasks - compiling against the wrong JSP libraries, perhaps.
Comment 2 David Williams CLA 2007-02-16 14:42:26 EST
If understand the big picture, I think the version of Tomcat is 
4.1.34 ... which uses/assume servlet/JSP of 2.3/1.2 ... and I think that is 
what is in the equinox.servlet jar.

I suspect during the "custom build" for this web app compile, the "new" bundles for javax.servlet and javax.servlet.jsp are getting in the mix (and they are 2.4/20). 

Comment 3 Mark Hutchinson CLA 2007-02-16 15:00:35 EST
When I dropped in the wsexplorer.war from an M4 build into the WSE plugin in this M5 build things worked properly, which to me indicates that there is some kind of build issue with the war.

Tracing through the explorer JSPs, the actual exception that gets thrown is a java.lang.NoClassDefFoundError: javax.servlet.ServletContext. 

Could the "new" bundles for javax.servlet and javax.servlet.jsp that are getting in the mix cause this problem?  If so then maybe that is what is causing this problem
Comment 4 David Williams CLA 2007-02-19 12:41:17 EST
FYI, I've added verbose="true" to javac task in build-war.xml, to attempt to better capture what's going on. 

I have a working hypotheis that we need to get servlet/JSP of 2.3/1.2 on the classpath during the build, since the equinox.servlet bundle is not longer there. 

In fact, during this "wst" part of the build, neither javax.servlet bundle is there.  If I pulled these in early, do you think the 2.4/2.0 versions of javax.servlet and javax.servlet.jsp would work? 


Comment 5 David Williams CLA 2007-02-19 13:45:36 EST
The verbose="true" didn't produce more output ... at least where I could find it, but, looking at the build-war.xml file, it seems to me that the servlet jars are not there on the classpath ... and, I'm guessing, they just happened to be there in the past. 

So, I think it worth trying to add following to the custom build, and I'll add them _first_ in the list, and I think may fix it all up: 

<fileset dir="${buildDirectory}/plugins/org.eclipse.wst.ws.explorer/servletapi" >
     <include name="*.jar"/>
</fileset>


Comment 6 David Williams CLA 2007-02-19 13:46:30 EST
Hmmm, I just tried this with the M5 build, and it seemed to work ok ... obviously something complex is going on here. 

Comment 7 Mark Hutchinson CLA 2007-02-19 14:19:22 EST
I have also just tried on the M5 Build (S-2.0M5-200702190651) and the web services explorer is working for me as well.  I used the WSE to search a UDDI registry and to test a web service wsdl and everything worked okay.
Comment 8 David Williams CLA 2007-02-19 14:48:17 EST
ok, why dont' we close this as worksforme for now. 

We'll need to fix this part of the custom build after M5 anyway, since the tomcat plugin is leaving ... so, we'll see if this whole custom build can be improved then. 
Comment 9 Mark Hutchinson CLA 2007-02-19 17:42:58 EST
now works for me as well.  Verified and closing.
Comment 10 Mark Hutchinson CLA 2007-03-22 15:45:45 EDT
I ran into this problem again while smoke testing this week's build (I-I200703220755-200703220755).  I didn't see this problem on 1.5.4 or on last week's smoke test so I'm not sure what changed to cause this.  My tomcat log looks the same as in comment 1.  I'll attach the log to this bug.
Comment 11 Mark Hutchinson CLA 2007-03-22 15:46:41 EDT
Created attachment 61735 [details]
catalina log
Comment 12 Chris Brealey CLA 2007-03-22 16:03:07 EDT
Updated target to M6. Gil, over to you to chase.
Comment 13 Andrew Mak CLA 2007-03-27 18:32:10 EDT
I think I may have found the problem.  I noticed in the recent builds, there's a new org.apache.jasper jar in the plugin directory.  This version is newer than the one in org.eclipse.tomcat*/ plugin which we is what we should be building the WSE with.  But somehow, we seem to be sucking in the newer org.apache.jasper stuff which is not compatiable with tomcat's version.

I was able to rebuild the WSE and run it in self-hosting env by adding an exclusion rule to build-war-pde.xml

<fileset dir="${baseLocation}/plugins">
   <exclude name="org.apache.jasper*.jar" />     <-- added this
   <include name="org.eclipse.tomcat*/*.jar" />
</fileset>
Comment 14 Andrew Mak CLA 2007-03-27 19:09:09 EDT
actually it's the section in the javac task that seems to do the trick:

<fileset dir="${baseLocation}/plugins">
    <exclude name="org.apache.jasper*.jar" />
    <include name="**/*.jar" /> 
</fileset>
Comment 15 Chris Brealey CLA 2007-03-28 09:41:03 EDT
Andrew, good sleuthing. I've committed changes based on your recommendation to build-war-pde.xml and build-war.pde. The WSE builds and launches correctly.
Comment 16 Chris Brealey CLA 2007-03-28 09:41:30 EDT
Moved to assigned state. Will release changes later today.
Comment 17 Chris Brealey CLA 2007-03-28 10:41:16 EDT
Released to HEAD, tag v200703281434. Reminder to Mark, Andrew or myself to try the next available continuous or integration build to see if the change to build-war.xml works as well as the change to build-war-pde.xml.
Comment 18 Mark Hutchinson CLA 2007-04-03 15:34:16 EDT
Confirmed fixed on last week's smoke test.  Closing this bug.