Here is a scenario.

I created a reloadable webapp in my tomcat installation, created the directory structure:

webapps/test/WEB-INF/lib
webapps/test/WEB-INF/classes

I then create a symlink from classes to where my code package resides:

ln -s $HOME/source/testPackage webapps/test/WEB-INF/classes

in $HOME/source/testPackage resides a java file TestServlet.java and its compiled version TestServlet.class

TestServlet.java is a servlet class in the testPackage package

Tomcat runs as my user, its installed in my home directory, my catalina.policy has:
grant {
permission java.security.AllPermission;
};


When i try to load the servlet, i get the following exception:
Wrapper cannot find servlet class testPackage.TestServlet or a class it depends on

I do the following:

cd webapps/test/WEB-INF/classes
rm -f testPackage (remove the link)

cp -r $HOME/source/testPackage .


restart tomcat,
go to the URL of the servlet, and it works fine.

Why does it not work with the symbolic link? Is there an option i can give somewhere to tomcat's classloader to follow symbolic links?

it would make my life so much easier since I am trying to develop an app with thousands of classes and hundreds of packages, modifying my build system to send all the classes to the tomcat dir would be a hassle.

Thanks,
Eugene


--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to