From: Alexis O'C. <ale...@co...> - 2005-07-13 13:12:15
|
Antony Corfield wrote: > Why are web.xml and context.xml in this directory and not WEB-INF? Or, > why doesn't build.xml put them there? > OK, here's a comprehensive answer! Both the web.xml and context.xml in /etc are never used *as-is*. Each contain tokens intended to be replaced with text strings that are more meaningful @DISPLAY_NAME@ and @DOC_BASE@ respectively. Therefore their use is entirely driven from the build.xml. The web.xml does indeed end up under ${build}/../WEB-INF/, having had it's display name set to something like 'bodington (v2.4.3)' (in Tomcat this appears in the HTML manager application). The context.xml is in particular required by the target deploy-local-5_5. In order to deploy a web-app from a local file system ('deploy local') that isn't under ${catalina.home}/webapps onto Tomcat 5.5 requires this jiggery-pokery. I came to this through trial and error, so I know that it is necessary, but that it does work(!). It *can* go under ${build}/../WEB-INF/ if you're deploying it as a war file), but that's not how I use it (it would be superfluous for a war deployed to JBoss say). Alexis |