Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 335748 - Custom context hot removal causes war redeploy (jetty-deploy)
Summary: Custom context hot removal causes war redeploy (jetty-deploy)
Status: RESOLVED WONTFIX
Alias: None
Product: Jetty
Classification: RT
Component: server (show other bugs)
Version: unspecified   Edit
Hardware: PC All
: P3 minor (vote)
Target Milestone: 7.2.x   Edit
Assignee: Greg Wilkins CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-28 19:42 EST by Davide De Rosa CLA
Modified: 2011-01-30 23:43 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Davide De Rosa CLA 2011-01-28 19:42:46 EST
Build Identifier: 20100917-0705

I noticed this inspecting MonitoredDirAppProviderRuntimeUpdatesTest.testAfterStartupThenRemoveContext(). Given a "contexts/foo.xml" pointing to a "webapps/foo.war", WebAppProvider.Filter prevents foo.war being deployed in a new context as long as foo.xml exists. Therefore, once foo.xml is removed foo.war gets redeployed alone.

There's a commented FIXME task in the test highlighing the issue, but I post this as Minor as I don't know the intended behaviour. Should the deployer delete foo.war as well? If so, I could upload a patch.

Reproducible: Always

Steps to Reproduce:
1. Create your foo.war web application
2. Create a foo.xml context configuration file defining a WebAppContext pointing to foo.war
3. Copy foo.war to "webapps" and foo.xml to "contexts" under the jetty distribution
4. Delete foo.xml
5. foo.war redeploys alone
Comment 1 Greg Wilkins CLA 2011-01-30 23:43:19 EST

The current behaviour is correct, but a little undesirable.
I think it is probably the best we can do for a one-size-fits all distribution and also to keep with existing doco etc.

For a non-default deployment, the solution is to either:

a) not use the webapp and context deployers/providers at the same time
b) don't use the webapps directory as the location of wars deployed by context/foo.xml


regards