Issue #1602 - Reverting AbstractLifeCycle changes per review

This commit is contained in:
Joakim Erdfelt 2018-01-11 16:16:26 -06:00
parent 4ba0277c37
commit f3c36f804a
2 changed files with 2 additions and 3 deletions

View File

@ -206,7 +206,7 @@ public abstract class AbstractLifeCycle implements LifeCycle
listener.lifeCycleStopped(this); listener.lifeCycleStopped(this);
} }
protected void setFailed(Throwable th) private void setFailed(Throwable th)
{ {
_state = __FAILED; _state = __FAILED;
if (LOG.isDebugEnabled()) if (LOG.isDebugEnabled())

View File

@ -553,8 +553,7 @@ public class WebAppContext extends ServletContextHandler implements WebAppClassL
// start up of the webapp context failed, make sure it is not started // start up of the webapp context failed, make sure it is not started
LOG.warn("Failed startup of context "+this, t); LOG.warn("Failed startup of context "+this, t);
_unavailableException=t; _unavailableException=t;
setAvailable(false); // webapp cannot be accessed setAvailable(false); // webapp cannot be accessed (results in status code 503)
setFailed(t); // be a proper Jetty LifeCycle participant and notify listeners of failure
if (isThrowUnavailableOnStartupException()) if (isThrowUnavailableOnStartupException())
throw t; throw t;
} }