https://bz.apache.org/bugzilla/show_bug.cgi?id=57700
--- Comment #4 from Violeta Georgieva <violet...@apache.org> --- Hi, I succeeded to reproduce the scenario on all Tomcat versions. The issue is the following: - The implementation of Manager web app invokes HostConfig to deploy the web application. ... at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:186) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:726) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:718) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:941) ... - In ContainerBase.addChildInternal if the child's start fails then the event ADD_CHILD_EVENT is not sent. - MapperListener will not be added to the context's listeners because it will not receive the event ADD_CHILD_EVENT - Later on when one tries to start the context again MapperListener will not be notified. The test testWebappListenerConfigureFail() is successfull because it explicitly sets ((ContainerBase) tomcat.getHost()).setStartChildren(false); with this flag when ContainerBase.addChildInternal is invoked, the child's start will be skipped and the event ADD_CHILD_EVENT will be sent. What do you think if we move the notification for event ADD_CHILD_EVENT before children start? (see below) Regards, Violeta Index: ContainerBase.java =================================================================== --- ContainerBase.java (revision 1686237) +++ ContainerBase.java (working copy) @@ -714,6 +714,8 @@ children.put(child.getName(), child); } + fireContainerEvent(ADD_CHILD_EVENT, child); + // Start child // Don't do this inside sync block - start can be a slow process and // locking the children object can cause problems elsewhere @@ -728,8 +730,6 @@ ("ContainerBase.addChild: start: " + e); } } - - fireContainerEvent(ADD_CHILD_EVENT, child); } -- You are receiving this mail because: You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org