Return-Path: Delivered-To: apmail-xml-axis-user-archive@xml.apache.org Received: (qmail 76652 invoked by uid 500); 12 Nov 2002 21:11:15 -0000 Mailing-List: contact axis-user-help@xml.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-user@xml.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list axis-user@xml.apache.org Received: (qmail 76637 invoked from network); 12 Nov 2002 21:11:15 -0000 Message-ID: <3DD16E8D.2040809@cadrc.calpoly.edu> Date: Tue, 12 Nov 2002 13:11:41 -0800 From: Steven Gollery Reply-To: axis-user@xml.apache.org User-Agent: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; rv:0.9.4.1) Gecko/20020314 Netscape6/6.2.2 X-Accept-Language: en-us MIME-Version: 1.0 To: axis-user@xml.apache.org Subject: Re: java.lang.NoClassDefFoundError is plaguing me References: <20021108234332.30108.qmail@mail.com> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N I've also had similar problems with compiling JSPs under TOMCAT. I think what's happening is that, since a JSP has to be compiled, TOMCAT runs javac. But javac obviously doesn't use the same custom class loader that Axis uses, so in order to make those jars visible to the compiler, they have to be in the classpath, or in a directory like common/lib where Tomcat can find them and add them to the classpath. Steve Gollery sgollery@cadrc.calpoly.edu Reynardine wrote: >While its not a permanent or architecurally satisfactory solution ... have you tried copying jdom.jar to the Tomcat/common/lib directory ? > >I fixed a similar problem this way. > >-Rey > >----- Original Message ----- >From: greyson.smith@convergys.com >Date: Fri, 8 Nov 2002 11:49:17 -0700 >To: axis-user@xml.apache.org >Subject: java.lang.NoClassDefFoundError is plaguing me > > >>I have been struggling w/ this for a few days, and have been to the >>archives and back, and haven't found a solution. Perhaps someone here has >>run into this problem and can point out to me where I went wrong. >> >>I am using tomcat 4.1.12 as my server, and i have placed axis 1.0 under the >>webapps folder, like so... >> >>webapps >> axis >> WEB-INF >> classes >> lib >> >>In the lib directory I placed all the jar files that my service is reliant >>upon. However...when I execute a service from a jsp, I find errors telling >>me that objects that I placed in the lib directory can't be found. >> >>The only way I have solved it is to place the specific jars in the >>classpath, but that defeats the purpose of this architecture. >> >> >>The specific jar that I'm struggling w/ at the moment is the jdom.jar. I >>created a simple jsp page where I create a jdom Document, just as a sanity >>check that the webapp can see it, and that goes fine.... Then I execute >>the soap service, and I get an error telling me that org/jdom/Document >>cannot be found. >> >>Here is a copy of the test code I am using, in case it helps solve the >>problem, and I will aslo provide a snippet of the error. >> >> >><% Object ret=null; >> try { >> try{ >> org.jdom.Document doc = new Document(); >> System.out.println( "************** " + doc.getClass >>().getName() + " **************" ); >> } >> catch(Exception e){System.out.println("Can't print the >>document " + e.toString());} >> //String endpoint >>="http://localhost:8080/axis/services/CTPortal"; >> String endpoint >>="http://localhost:8080/axis/services/CTPortal"; >> >> Service service = new Service(); >> Call call = (Call) service.createCall(); >> >> call.setTargetEndpointAddress( new java.net.URL(endpoint) ); >> call.setOperationName( "login" ); >> >> ret = call.invoke( new Object[] { "0", "ctrd", new Integer(92) >>} ); >> System.out.println(ret.getClass().getName()); >> System.out.println("Sent 'Hello!', got '" + ret + "'"); >> } catch (Exception e) { >> //e.printStackTrace(); >> System.out.println("Damn Dirty Error"); >> } >>%> >> >> >> >>The error: >>- Exception: >>AxisFault >> faultCode: {http://xml.apache.org/axis/}Server.userException >> faultString: java.lang.reflect.InvocationTargetException >> faultActor: null >> faultDetail: >> stackTrace: java.lang.reflect.InvocationTargetException: >>java.lang.NoCla >>ssDefFoundError: org/jdom/Document >> at cvg.borg.services.CTPortal.login(CTPortal.java:38) >> at java.lang.reflect.Method.invoke(Native Method) >> at >>org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.j >>ava:372) >> at >>org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider >>.java:292) >> >> >>-- >>"NOTICE: The information contained in this electronic mail transmission is >>intended by Convergys Corporation for the use of the named individual or >>entity to which it is directed and may contain information that is >>privileged or otherwise confidential. If you have received this electronic >>mail transmission in error, please delete it from your system without >>copying or forwarding it, and notify the sender of the error by reply email >>or by telephone (collect), so that the sender's address records can be >>corrected." >> >> >