tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Øyvind Vestavik <Oyvind.Vesta...@idi.ntnu.no>
Subject RE: classpath-problem??
Date Wed, 20 Feb 2002 14:54:26 GMT

I found that it worked when I placed the jar-files in the
JAVA-HOME/jre/lib/ext.
I'm still uncertain of hoe this will work when packaging in a war file,
but thanks to for all replies.

Øyvind

Øyvind Vestavik
Øvre Møllenberggt 44b
7014 Trondheim
oyvindve@idi.ntnu.no
41422911

On Wed, 20 Feb 2002, Larry Isaacs wrote:

> It's not that the container can't see the class, but that
> a class is being loaded that depends on XMLDBException.
> That class is being loaded in a classloader that can't
> "see" XMLDBExceptions. Unfortunately, this "problem" class
> that depends on XMLDBException may be many levels of
> dependency from the original class that is being loaded.
> This can make it very difficult to track down.  The
> stack trace can but doesn't always help much.
>
> Since XMLDBException would appear to be in the "classpath"
> classloader, the "problem" class would likely be in the
> "extensions" classloader, i.e. the jre/lib/ext directory.
> See if there are any jars there that might have depencencies
> on classes in the two jars you mention.
>
> Hope this helps.
>
> Cheers,
> Larry
>
> > -----Original Message-----
> > From: Øyvind Vestavik [mailto:Oyvind.Vestavik@idi.ntnu.no]
> > Sent: Wednesday, February 20, 2002 8:47 AM
> > To: Tomcat Users List
> > Subject: classpath-problem??
> >
> >
> >
> > I'm building a servlet which is accessing a dbxm/Windice
> > database via a
> > separat class (loginTest.java). Connecting to Xindice means I
> > have to use classes contained in 'xmldb.jar' and 'dbxml.jar'.
> >
> > These jar files are referenced from my classpath. Both the class
> > (loginTest.java) and the servlet calling it compiles ok, and
> > can be run
> > from command but as I try to let the serlet create the separat class a
> > javax.ServletException is thrown.
> >
> > The message shown is this :
> >    java.lang.NoClassDefFoundError : org/xmldb/api/base/XMLDBException.
> >
> > It seems like this runtime error is due to that the servlet
> > engine cant
> > find the Exception class, because it doesn't have access to the
> > classpath????? Where should the jar files be places and what
> > effect will
> > that have on making a war-file of my application???
> >
> > Probabaly a common problem???
> >
> > Øyvind Vestavik
> >
> > Øyvind Vestavik
> > Øvre Møllenberggt 44b
> > 7014 Trondheim
> > oyvindve@idi.ntnu.no
> > 41422911
> >
> > On Wed, 20 Feb 2002, Larry Isaacs wrote:
> >
> > > The stack trace doesn't show any classes coming from your
> > > "com" or "dir" directories under WEB-INF/classes.  Is this
> > > the same problem?  Where are each of the "kitabe" classes
> > > located?
> > >
> > > Cheers,
> > > Larry
> > >
> > > > -----Original Message-----
> > > > From: Amine AMAR [mailto:a.amar@dns1.caciopee.com]
> > > > Sent: Tuesday, February 19, 2002 4:11 PM
> > > > To: Tomcat Users List
> > > > Subject: Re: classes visibility in the WEB-INF dir
> > > >
> > > >
> > > > Thank's for your reply, but my web application has no
> > > > particular definition. The stack trace is as follows (root cause):
> > > >
> > > > java.lang.NoClassDefFoundError: kitabe/SearchUtilities
> > > > 	at
> > > > kitabe.dal.home.BookHome.rechercheMulticriteres(BookHome.java:485)
> > > > 	at
> > > > kitabe.bl.Catalogue.rechercheMulticriteres(Catalogue.java:231)
> > > > 	at org.apache.jsp.results$jsp._jspService(results$jsp.java:160)
> > > > 	at
> > > >
> > org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
> > > > 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> > > > 	at
> > > > org.apache.jasper.servlet.JspServlet$JspServletWrapper.service
> > > > (JspServlet.java:202)
> > > > 	at
> > > > org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet
> > > > .java:382)
> > > > 	at
> > > > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:474)
> > > > 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> > > > 	at
> > > > org.apache.catalina.core.ApplicationFilterChain.internalDoFilt
> > > > er(ApplicationFilterChain.java:247)
> > > > 	at
> > > > org.apache.catalina.core.ApplicationFilterChain.doFilter(Appli
> > > > cationFilterChain.java:193)
> > > > 	at
> > > > org.apache.catalina.core.StandardWrapperValve.invoke(StandardW
> > > > rapperValve.java:243)
> > > > 	at
> > > > org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
> > > > ipeline.java:566)
> > > > 	at
> > > > org.apache.catalina.core.StandardPipeline.invoke(StandardPipel
> > > > ine.java:472)
> > > > 	at
> > > >
> > org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
> > > > 	at
> > > > org.apache.catalina.core.StandardContextValve.invoke(StandardC
> > > > ontextValve.java:201)
> > > > 	at
> > > > org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
> > > > ipeline.java:566)
> > > > 	at
> > > > org.apache.catalina.valves.CertificatesValve.invoke(Certificat
> > > > esValve.java:246)
> > > > 	at
> > > > org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
> > > > ipeline.java:564)
> > > >
> > > > If you can just have a look at it and tell me if you see
> > > > anything wrong. The logs contain just the same info.
> > > >
> > > > Thank's again
> > > >
> > > > Amine
> > > >
> > > > ----- Original Message -----
> > > > From: "Larry Isaacs" <Larry.Isaacs@sas.com>
> > > > To: "'Tomcat Users List'" <tomcat-user@jakarta.apache.org>
> > > > Sent: Tuesday, February 19, 2002 9:01 PM
> > > > Subject: RE: classes visibility in the WEB-INF dir
> > > >
> > > >
> > > > > This error implies that a class that needs to "see" your
> > > > > "com" and/or "dir" classes is being loaded in a parent of
> > > > > the web application's class loader.  This "parent"
> > > > > classloader is at or between the "classpath" classloader
> > > > > and the web application classloader.  The stacktrace
> > > > > should give you a clue as to who this class is.
> > > > >
> > > > > Cheers,
> > > > > Larry
> > > > >
> > > > > > -----Original Message-----
> > > > > > From: Amine AMAR [mailto:a.amar@dns1.caciopee.com]
> > > > > > Sent: Tuesday, February 19, 2002 3:56 PM
> > > > > > To: Tomcat Users List
> > > > > > Subject: classes visibility in the WEB-INF dir
> > > > > >
> > > > > >
> > > > > > Hi all,
> > > > > >
> > > > > > I've been using TC for a couple of years, and I have a fancy
> > > > > > little question :)
> > > > > >
> > > > > > I have two directories (com and dir) in the WEB-INF\classes
> > > > > > directory of an application context. The classes in dir are
> > > > > > not visible (noClassDefFoundError).
> > > > > > When I put the path of my WEB-INF\classes in the startup
> > > > > > classpath of catalina.bat, the classes are visible.
> > > > > >
> > > > > > Does anyone ave a clue why?
> > > > > >
> > > > > > PS: I have already double checked all spelling of directories
> > > > > > and hierarchies for errors.
> > > > > >
> > > > > > Thank's all
> > > > > >
> > > > > > Amine
> > > > > >
> > > > >
> > > > > --
> > > > > To unsubscribe:
> > > > <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> > > > > For additional commands:
> > > > <mailto:tomcat-user-help@jakarta.apache.org>
> > > > > Troubles with the list:
> > > > <mailto:tomcat-user-owner@jakarta.apache.org>
> > > > >
> > > > >
> > > >
> > > >
> > > > --
> > > > To unsubscribe:
> > <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> > > > For additional commands:
> > <mailto:tomcat-user-help@jakarta.apache.org>
> > > > Troubles with the list:
> > <mailto:tomcat-user-owner@jakarta.apache.org>
> > > >
> > >
> > > --
> > > To unsubscribe:
> > <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> > > For additional commands:
> > <mailto:tomcat-user-help@jakarta.apache.org>
> > > Troubles with the list:
> > <mailto:tomcat-user-owner@jakarta.apache.org>
> > >
> >
> >
> > --
> > To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> > For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
> > Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>
> >
>
> --
> To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
> Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>
>


--
To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>


Mime
View raw message