*
The moose likes Tomcat and the fly likes Multiple apps in Tomcat Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Multiple apps in Tomcat" Watch "Multiple apps in Tomcat" New topic
Author

Multiple apps in Tomcat

Rajan Chinna
Ranch Hand

Joined: Jul 01, 2004
Posts: 320
Lets say i have 3 different web applications under webapps folder as
App1, App2 and App3. I want all three apps to be running when tomcat is started.

1.What should my Context docBase in server.xml pointing to....?
<Context path="" docBase="???" debug="0" reloadable="true">

2.Why my new jsp is not reloaded automatically when i set like this....?
<Context path="" docBase="App1" debug="0" reloadable="true">

Thanks
Rajan Chinna
Ranch Hand

Joined: Jul 01, 2004
Posts: 320
Can somebody give me the best suggestion about how to organize the folder structure which cater different web applications in single tomcat instance....

Thanks
somkiat puisungnoen
Ranch Hand

Joined: Jul 04, 2003
Posts: 1312
Originally posted by Rajan Chinna:
Lets say i have 3 different web applications under webapps folder as
App1, App2 and App3. I want all three apps to be running when tomcat is started.


Thanks


Sure, All web application should be run, After tomcat server started.


1.What should my Context docBase in server.xml pointing to....?
<Context path="" docBase="???" debug="0" reloadable="true">



In tomcat 4.x/5.x, you don't worry in this issue which tomcat server automatically manage.

"docBase" attribute name of Context tag, it's refer to directory in webapp directory but you can refer to another directory (c:\, d:\)

2.Why my new jsp is not reloaded automatically when i set like this....?
<Context path="" docBase="App1" debug="0" reloadable="true">


By default , Tomcat can automatically reloaded jsp.

And another solution : you can reload webapp in Tomcat Manager.


SCJA,SCJP,SCWCD,SCBCD,SCEA I
Java Developer, Thailand
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Multiple apps in Tomcat
 
Similar Threads
Help! adding a webapplication to tomcat 4
Reloading Application
Automatically Reloading Servlets in tomcat
multiple apps pointing so same docbase locking the log files from rolling
How Tomcat Works book - development question