tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Srinivas Kurella <>
Subject RE: context related classpath question -ASAP
Date Thu, 08 Feb 2001 01:16:21 GMT
Thanks for the clarification. I have a servlet to be loaded on startup which
is looking for another class. They are in different jars under the same app.
However the servlet can't see the class.

-----Original Message-----
From: Craig R. McClanahan []
Sent: Wednesday, February 07, 2001 5:13 PM
Subject: Re: context related classpath question -ASAP

Srinivas Kurella wrote: 


Tomcat documentation says that all the jars under the WEB-INF/lib directory
in a context are automatically added to the CLASSPATH. 

This is not precisely what happens. 

I am finding this not to be true. I have to add them explicitly to the
Am i missing something ???

What happens is that classes in JAR files under WEB-INF/lib, and unpacked
classes under WEB-INF/classes, are automatically made visible to other
classes in the same web application.  They are *not* added to the CLASSPATH
environment variable, which makes sense when you remember that CLASSPATH is
global to the entire JVM, but the set of classes visible to each webapp are
unique to that webapp. 

Craig McClanahan 

View raw message