tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Justin Ruthenbeck <just...@nextengine.com>
Subject Re: classpaths
Date Sat, 26 Apr 2003 00:11:41 GMT
At 04:33 PM 4/25/2003, you wrote:
>do classpaths automatically include subdirectories?
>
>i.e. if I put /usr/local/tomcat into my classpath will I be able to find 
>the classes defined in: /usr/local/tomcat/common/lib/

The smart-ass answer is:
Yes, but only if your classes are defined as part of the common.lib package.

The helpful answer in the general case is:
No, you have to put each directory on your classpath separately.

The helpful answer for Tomcat specifically is:
Provided you're using a fairly recent Tomcat version, you don't have to 
worry about it.  Jars (*not* individual classes) that you put in either 
common/lib or server/lib will be picked up automatically by Tomcat when it 
starts -- that's why those directories are special and revered.  If you're 
not aware of the classloader issues involved with these, be sure to read 
and understand the oft-referenced guide:

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/class-loader-howto.html

Happy trails,
justin


>  or /usr/local/tomcat/server/lib/, or do I have to specify each subdir as 
> well?
>
>-Cam


____________________________________
Justin Ruthenbeck
Software Engineer, NextEngine Inc.
justinr - AT - nextengine DOT com
Confidential
    See http://www.nextengine.com/confidentiality.php
____________________________________


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


Mime
View raw message