Meaningless Drivel is fun!
The moose likes Tomcat and the fly likes About Eclipse and Tomcat configuration Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "About Eclipse and Tomcat configuration" Watch "About Eclipse and Tomcat configuration" New topic

About Eclipse and Tomcat configuration

Abhishek Asthana
Ranch Hand

Joined: Sep 08, 2004
Posts: 146
I am just so confused about it!
I have added a Tomcat 5.5 server to my Eclipse 3.3. I created a 'Dynamic Web Project' (named TestProject) in Eclipse Workspace (Default Location) and deployed it on this server.

It works fine in Eclipse internal browser as well as external browsers.

Now what I am not able to understand is this: There is no folder or WAR in webapps directory in the TOMCAT_HOME of the target Tomcat installation. Then how is this project able to run?

If I am not getting a 404 when trying to run it, it means that Tomcat is able to get the deployment even though it is not in webapps directory.

Can someone please tell how is this done? Does eclipse make some entry in some file?

Any pointers appreciated!

Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 15082

I'm not 100% sure about how it works, but as far as I know it just runs out of your Eclipse workspace: Eclipse starts up Tomcat in such a way that it deploys the project that's in your workspace, without the need to copy anything to your Tomcat installation (which would not work on some systems - for example on Unix-like operating systems, normal users probably have no rights to write to the Tomcat installation directory).

If you really want to know the details of how it works, then you could probably find more info about it in the documentation of the Eclipse Web Tools Platform project.
[ March 19, 2008: Message edited by: Jesper Young ]

Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 8 API documentation
I agree. Here's the link:
subject: About Eclipse and Tomcat configuration
jQuery in Action, 3rd edition