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: [EMAIL PROTECTED]
Date: Fri, 8 Nov 2002 11:49:17 -0700
To: [EMAIL PROTECTED]
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."
> 
> 

-- 
__________________________________________________________
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup

Single & ready to mingle? lavalife.com:  Where singles click. Free to Search!
http://www.lavalife.com/mailcom.epl?a=2116

Reply via email to