tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Arshan Dabirsiaghi" <arshan.dabirsia...@aspectsecurity.com>
Subject RE: Major Tomcat classloading issues with javaagent command line switch
Date Tue, 06 Apr 2010 13:48:39 GMT
I've tried this outside Eclipse with Tomcat 6.0.26 on both Java 1.5.0_22
and Java 1.6.0_18:

SET JAVA_OPTS=-javaagent:C:\path-to-agent.jar

JSP's seem to work fine, but anytime you try to access a Servlet you get
the same thing:

javax.servlet.ServletException: Error allocating a servlet instance
 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:102)
 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:2
98)
 
org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.j
ava:859)
 
org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.proce
ss(Http11AprProtocol.java:579)
 
org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1555)
        java.lang.Thread.run(Thread.java:619)

java.lang.NoClassDefFoundError: javax/servlet/http/HttpServlet
        java.lang.ClassLoader.findBootstrapClass(Native Method)
 
java.lang.ClassLoader.findBootstrapClassOrNull(ClassLoader.java:927)
        java.lang.ClassLoader.loadClass(ClassLoader.java:298)
        java.lang.ClassLoader.loadClass(ClassLoader.java:296)
        sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
        java.lang.ClassLoader.loadClass(ClassLoader.java:248)
 
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader
.java:1431)
 
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader
.java:1361)
 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:102)
 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:2
98)
 
org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.j
ava:859)
 
org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.proce
ss(Http11AprProtocol.java:579)
 
org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1555)
        java.lang.Thread.run(Thread.java:619)

Can anyone else confirm?
Arshan

-----Original Message-----
From: Caldarale, Charles R [mailto:Chuck.Caldarale@unisys.com] 
Sent: Tuesday, April 06, 2010 12:34 AM
To: Tomcat Users List
Subject: RE: Major Tomcat classloading issues with javaagent command
line switch

> From: Arshan Dabirsiaghi
[mailto:arshan.dabirsiaghi@aspectsecurity.com]
> Subject: Major Tomcat classloading issues with javaagent command line
> switch
> 
> The bottom line appears to be this: across Tomcat and JDK versions,
you
> can't use the javaagent switch and have a working web app.

Wrong conclusion.  Try running Tomcat directly, not under Eclipse; the
problem you're having is most likely due to Eclipse insisting on doing
things its own way, ignoring configuration that you have set up.  Deploy
your war to a stand-alone Tomcat and try it again.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message