tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jacob Kjome <>
Subject Re: Tomcat 4.1 b9, Reload Context with Ant
Date Tue, 20 Aug 2002 01:39:09 GMT

What you need to use is a context configuration file.  That is, a file with 
the root element being <Context ....>.  Put all your resources within this 
that are needed by the webapp and then use the following:

             war="file://${build.home}/WEB-INF/contextConfigFile.xml" />

The contextConfigFile.xml contains a <Context ...> entry with the path and 
docRoot for the app.

Just a note.  I haven't gotten this to work on Windows even though Craig R. 
McClanahan says that it works for him on Unix.  However, I haven't tried it 
with the latest version 4.1.9.

If you get this to work for you, let me know.


At 06:16 PM 8/19/2002 -0700, you wrote:
>Hi All,
>I am trying to configure Tomcat and Ant so that I can type "ant reload" and
>the web application that I am running will be redeployed without restarting
>Tomcat.  This would really speed up development for me.
>The first issue is that I have the context set up with a couple of resources
>in the server.xml file.  Tomcat will autodeploy (but not start) this app
>even without a folder named $tomcat/webapps/myapp or a war file named
>$tomcat/webapps/myapp.war.  If I remove the context
>http://localhost:8080/manager/remove?path=/myapp, and then try to install
>the context
>http://localhost:8080/manager/reload?path=/myapp&war=file:/mybuild, the
>application can't find the resources, the MySQL database pool, or the mail
>Is there any way to have the /myapp server.xml resources not be removed from
>memory when the context is removed.  Or better yet, to have it put back in
>memory when you install a context at the path /myapp?
>Any help would be appreciated.
>To unsubscribe, e-mail:   <>
>For additional commands, e-mail: <>

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message