The hidden Tomcat folder of Eclipse

In my day to day work I use eclipse 3.3.0 for java development. Eclipse provides a very convenient way to create a dynamic web application (J2EE) and configure it with a server like tomcat or JBoss within eclipse itself. When you deploy your web application in the tomcat separately, you copy the web module directory or the war file to the webapps folder of tomcat. But when you do the same using eclipse, it does not copy any file related to the web application to your tomcat deployment. So when sometime you need to debug your web application, say, by making some temporary changes in JSP files or to see the java files generated for the JSP files, at that time you need to know the actual path where eclipse stores the web application. Eclipse actually creates a tomcat like folder structure in the current workspace. Following is the path of the webapps folder where you can find your web application:
  
Eclipse_Workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps
 
Where Eclipse_Workspace is the current workspace.

 If you have not configured the server for eclipse, the org.eclipse.wst.server.core folder remains empty.   

Enjoy Learning, 

Kamlesh  

    

 

Advertisements

3 thoughts on “The hidden Tomcat folder of Eclipse

  1. Kamlesh,

    Good piece of information. Though it seems to be quite obvious but it kept me in search mode for long and consequently I preferred to use the external tomcat.

    Wish to see more such stuff on your blog.

    – Sam

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s