tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jonathan Tiu <Jonathan....@crystaldecisions.com>
Subject Problem reading resource file in WEB-INF\lib
Date Thu, 15 May 2003 16:49:39 GMT

Hi!

This is really stumping me so any help would be much appreciated!
I have a simple web app, called Foo, on Tomcat that makes use of a jar
called icu4j.jar (IBM ICU library). The jar is
in the lib directory

ie.  Foo\WEB-INF\lib\icu4j.jar

My application fails because it makes a call into the icu library which, in
turn, attempts to load a resource file  which is also in the icu4j.jar.
But the class loader seems to fail loading the resource file. I guess it
can't find it.


I have read the Tomcat documentation on class loading, etc. and it says:

"For classes and resources specific to a particular web application, place
unpacked classes and resources under /WEB-INF/classe of your web application
archive, or place JAR files containing those classes and resources under
/WEB-INF/lib of your web application archive"

So I don't need to do anymore configuration to tell Tomcat where to find the
resource file? I mean, the jar containing the file is in the classpath,
right?
I was thinking...is it when my code is run, it invokes the system
classloader which checks only the CLASSPATH and maybe doesn't check
WEB-INF\lib???

It isn't a bug in icu4j.jar because, running my java app outside of Tomcat,
works perfectly fine.

Thanks a lot!
Jonathan





---------------------------------------------------------------------
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