You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Vladislovas Razas <vl...@gemtek.lt> on 2004/06/16 16:35:24 UTC
Problem accessing WEB-INF/lib (Launching Tomcat from Eclipse without any plugins)
Hi,
I did set up Eclipse to run Tomcat. When I run Tomcat 5 standalone (I mean NOT from Eclipse) I don't have this problem. My application can't access WEB-INF/lib unless I also put all *.jar files in classpath. I know this should not be required and Tomcat would normally access them without classpath.
I configured Eclipse as follows:
Main class: org.apache.catalina.startup.Bootstrap
Program arguments: start
VM arguments: -Djava.endorsed.dirs="c:\java\tomcat\common\endorsed" -Dcatalina.base="c:\java\tomcat" -Dcatalina.home="c:\java\tomcat" -Djava.io.tmpdir="c:\java\tomcat\temp"
Local directory: C:\Java\tomcat\bin
Classpath bootstrap entries: c:\Java\jdk\jre\lib\rt.jar
User entries: bootstrap.jar (TOMCAT) and tools.jar (JDK)
Tomcat starts correctly but I get NoClassDefException when main application servlet tries to call that JAR (when running from Eclipse). I am sure I have that JAR in my WEB-INF/lib.
I don't understand how does Tomcat know it has to make WEB-INF/lib available and why it doesn't do it when I try to run it from Eclipse. Did I miss any settings?
My best regards,
Vladas
P.S. There is workaround by explicitly putting all jars in classpath but I am very anxious to understand why this is happening.