Bug 34399 - Undeploying fails when context defined in server.xml & server fails to stop
Undeploying fails when context defined in server.xml & server fails to stop
Status: RESOLVED FIXED
Product: Tomcat 5
Classification: Unclassified
Component: Webapps:Manager
5.5.7
Other other
: P4 normal (vote)
: ---
Assigned To: Tomcat Developers Mailing List
:
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2005-04-11 16:32 UTC by sherold
Modified: 2006-09-14 18:58 UTC (History)
3 users (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description sherold 2005-04-11 16:32:42 UTC
Steps to reproduce: 
 
1. autodeploy a web application by defining its context in server.xml 
2. start the Tomcat server 
3. use the Tomcat Manager to undeploy the application 
 
You will get the "OK - Undeployed application at context path /WebApplication" 
message, but the application will NOT be undeployed, it will be only stopped. 
 
If you try to stop the server after that, it will fail! 
 
I have used the shared installation (CATALINA_BASE dir), but I guess this 
won't work for standalone Tomcat isntallation either.
Comment 1 sherold 2005-04-11 16:33:58 UTC
One more thing, this works for Tomcat 5.0.x. 
Comment 2 Remy Maucherat 2005-04-11 16:42:18 UTC
In 5.5, the manager will only handle contexts deployed by the autodeployer.
Please don't insist for it to behave in a different way, it will not happen. The
other part of the bug has been fixed already.
Comment 3 Karel Zikmund 2005-04-11 16:51:00 UTC
So you claim that it is 'as designed' to restrict undeploy by manager of
autodeployed applications? (I'm OK with that)
But why the report is: "OK - Undeployed", if it is not true! I'd expect
different result message at least (it could be probably downgraded).
Comment 4 Remy Maucherat 2005-04-11 16:55:33 UTC
Hacking in contexts using server.xml is not recommended. I do not see any reason
to address this non issue.
Comment 5 Karel Zikmund 2005-04-11 17:36:50 UTC
I'm OK with not recommend using server.xml, but it is still part of product,
therefore valid issue, although with lower priority.
Comment 6 sherold 2005-04-11 17:53:07 UTC
I do not insist on this being considered as a serious issue, especially if the  
stopping has been fixed. However, I do not agree it is a "non issue". Defining  
context in the server.xml is a valid usecase, although not recommended and  
ugly, but it is still valid.  
  
I would expect the Tomcat Manager to behave reasonably which is returning  
something like "FAIL - Application cannot be undeployed..." and not claiming  
it was undeployed successfully, if it was not.  
  
Remy, please note that I've filed this issue in attempt to improve the Tomcat  
user experience. This usecase is not what I would personally do. However,  
users who are upgrading from erlier versions (3.x.x or 4.x.x) are often used  
to it and they would surely consider this as an issue. 
 
Btw, if this issue should be closed, it should be cloased as WONTFIX and not 
as INVALID. 
 
Anyway, thanks Remy for fixing the other issue! 
Comment 7 Mark Thomas 2006-09-15 01:58:13 UTC
I have fixed this by disabling undeploy for contexts defined in server.xml

This fix will be in 5.5.20 onwards