aspose file tools*
The moose likes Tomcat and the fly likes What is the classpath for Tomcat 5.5? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "What is the classpath for Tomcat 5.5?" Watch "What is the classpath for Tomcat 5.5?" New topic
Author

What is the classpath for Tomcat 5.5?

Ayanik Sil
Greenhorn

Joined: Sep 23, 2007
Posts: 27
Hello friends,
I am using Tomcat 5.5. Can you tell me that what should be in the classpath?
This is my present classpath.

"C:\Program Files\Apache Software Foundation\Tomcat 5.5\common\lib\commons-el.ja
r";"C:\Program Files\Apache Software Foundation\Tomcat 5.5\common\lib\jasper-run
time.jar";"C:\Program Files\Apache Software Foundation\Tomcat 5.5\common\lib\nam
ing-factory-dbcp.jar";"C:\Program Files\Apache Software Foundation\Tomcat 5.5\co
mmon\lib\jasper-compiler.jar";"C:\Program Files\Apache Software Foundation\Tomca
t 5.5\common\lib\jsp-api.jar";"C:\Program Files\Apache Software Foundation\Tomca
t 5.5\common\lib\naming-resources.jar";"C:\Program Files\Apache Software Foundat
ion\Tomcat 5.5\common\lib\jasper-compiler-jdt.jar";"C:\Program Files\Apache Soft
ware Foundation\Tomcat 5.5\common\lib\naming-factory.jar";"C:\Program Files\Apac
he Software Foundation\Tomcat 5.5\common\lib\servlet-api.jar";

Should any change needs to be done here?
Rahul Bhattacharjee
Ranch Hand

Joined: Nov 29, 2005
Posts: 2308
There should not be anything specific to tomcat in the classpath.Even the classpath is ignored by the tomcat's classloaders.

But for compilation of servlet java sources you would need to put the jar in the classpath which has the required classes.
What exactly is your issue ?
[ September 25, 2007: Message edited by: Rahul Bhattacharjee ]

Rahul Bhattacharjee
LinkedIn - Blog
Ayanik Sil
Greenhorn

Joined: Sep 23, 2007
Posts: 27
Hey,thanks for replying.
Regarding the above classpath mentioned,
can i put
"C:\Program Files\Apache Software Foundation\Tomcat 5.5\common\lib\*.jar"
in the classpath instead of mentioning all the jar files seperately?
Tarun Yadav
Ranch Hand

Joined: Sep 20, 2007
Posts: 134
Originally posted by Ayanik Sil:
Hey,thanks for replying.
Regarding the above classpath mentioned,
can i put
"C:\Program Files\Apache Software Foundation\Tomcat 5.5\common\lib\*.jar"
in the classpath instead of mentioning all the jar files seperately?


You need to mention each JAR individually.
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

What are you trying to do?

Like Raul said, Tomcat ignores your classpath when running.

If you are setting up your classpath for developing servlets, the only thing from Tomcat that you should need on your classpath is tomcat/common/lib/servlet-api.jar.


Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

Moving to our Tomcat forum
Ayanik Sil
Greenhorn

Joined: Sep 23, 2007
Posts: 27
shall i have to put all the jar files in my classpath?
or only the servlet-api.jar in the classpath for running Tomcat?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39549
    
  27
To reiterate what Rahul and Ben have said:

- For running Tomcat, you don't need to put anything in your classpath.

- For developing servlets, you'll need the servlet-api.jar file in your classpath.


Ping & DNS - updated with new look and Ping home screen widget
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: What is the classpath for Tomcat 5.5?
 
Similar Threads
please help! classpath not working
Please Help. cannot compile Assertions
Problem Compiling Beer servlet example in HF
Compilation problem in servlets
What is the classpath for Tomcat 5.5?