I've debugged the problem, here's the answer, in case someone else runs into the same problem.

the directory "WEB-INF" was in lowercase (e.g. web-inf) and tomcat couldn't find the web.xml that it contains as a result. The war ant task uses the right capitalization when it creates the war, so that's why it worked in .war form.

Thanks anyway,
Christian Nelson

Christian Nelson wrote:

Greetings,

I'm using the ant DeployTask in two different scenarios. One works as desired, the other not so much. I'm trying to figure out what I'm not doing right.

Scenario 1: Deploy a packaged .war file.

This is works great. The war parameter to the install task is war="jar:file:/${basedir}/${dist}/${war.application}!/" (which obvious resolves to a real file once the properties are set. The problem is I need to go through the whole undeploy, create war, deploy war cycle.

Scenario 2: Deploy a unpacked (exploded) web app (which exists on the server).

If I take the .war and explode it, and then try to add the directory where it lives as follows:

war="file:/${basedir}/war/"

It reports success, and shows up when the web applications are listed, but it's not really set-up correctly because the file "web-inf/web.xml" doesn't seem to be processed. Here's why I think that:

INFO: Missing application web.xml, using defaults only StandardEngine[Catalina].StandardHost[localhost].StandardContext[/archiver]


Note: I have also tried the InstallTask, and I've tried both 5.0.27 as well as 4.1.30.


Really, my goal, and I don't care how I achieve it, is that during development, I want to have tomcat serving the exploded version of the app so I can make changes on the fly (or with a reload) instead of having to undeploy, war, deploy with each change. What's the best way to do this?

Thanks in advance,
Christian


-- Christian Nelson -- (e) [EMAIL PROTECTED] -- (m) 415-378-3988



Reply via email to