X-Git-Url: https://code.wpia.club/?p=gigi.git;a=blobdiff_plain;f=lib%2Fjetty%2Forg%2Feclipse%2Fjetty%2Futil%2Fcomponent%2FContainerLifeCycle.java;h=4756bc12a092fa0fc09bb737cac94ceb6c3bc016;hp=464c0f7e4a88b18e2540b9c99d609076f4b91ecc;hb=ba4f228fa9f72d50991a2218cfd83987ef5d385e;hpb=875b5e9651498a0cd8e0001c0742ba843e47cad0 diff --git a/lib/jetty/org/eclipse/jetty/util/component/ContainerLifeCycle.java b/lib/jetty/org/eclipse/jetty/util/component/ContainerLifeCycle.java index 464c0f7e..4756bc12 100644 --- a/lib/jetty/org/eclipse/jetty/util/component/ContainerLifeCycle.java +++ b/lib/jetty/org/eclipse/jetty/util/component/ContainerLifeCycle.java @@ -1,6 +1,6 @@ // // ======================================================================== -// Copyright (c) 1995-2014 Mort Bay Consulting Pty. Ltd. +// Copyright (c) 1995-2016 Mort Bay Consulting Pty. Ltd. // ------------------------------------------------------------------------ // All rights reserved. This program and the accompanying materials // are made available under the terms of the Eclipse Public License v1.0 @@ -320,7 +320,8 @@ public class ContainerLifeCycle extends AbstractLifeCycle implements Container, throw new RuntimeException(e); } - LOG.debug("{} added {}",this,new_bean); + if (LOG.isDebugEnabled()) + LOG.debug("{} added {}",this,new_bean); return true; } @@ -523,6 +524,7 @@ public class ContainerLifeCycle extends AbstractLifeCycle implements Container, { if (_beans.remove(bean)) { + boolean wasManaged = bean.isManaged(); unmanage(bean); @@ -533,7 +535,7 @@ public class ContainerLifeCycle extends AbstractLifeCycle implements Container, removeEventListener((Container.Listener)bean._bean); // stop managed beans - if (bean._managed==Managed.MANAGED && bean._bean instanceof LifeCycle) + if (wasManaged && bean._bean instanceof LifeCycle) { try {