tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Simone Pierazzini <make...@gmail.com>
Subject weird tomcat5.0.30 behaviour with jar in WEB-INF/classes
Date Wed, 01 Dec 2004 14:37:02 GMT
Hi,
I use URLClassLoader to create class loaders that manage jars in WEB-INF/classes
In WEB-INF/classes I have many jars that are incompatible each other
(they have different classes with the same name inside).

Suppose I want to load the following files as resources from a classLoader:
- pippo.txt
- pippo.jar

In the first case I tried the line:
classLoader.getResource("pippo.txt") 

and correctly the returned URL was:
 file:/ ... /myapp/WEB-INF/classes/pippo.txt

where "..." stands for $CATALINA_HOME
while, trying to get the second file:
classLoader.getResource("pippo.jar")

tomcat returned the following url:
 file:/ ... /work/Catalina/localhost/myapp/loader/pippo.jar

but the directory "... /work/Catalina/localhost/myapp/loader/" does
not contain pippo.jar
that is placed in  .../myapp/WEB-INF/classes/pippo.jar

thanks in advance
Simone Pierazzini

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