diff options
Diffstat (limited to 'jdisc_core/src/main/java/com/yahoo/jdisc/core/ActiveContainer.java')
-rw-r--r-- | jdisc_core/src/main/java/com/yahoo/jdisc/core/ActiveContainer.java | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/jdisc_core/src/main/java/com/yahoo/jdisc/core/ActiveContainer.java b/jdisc_core/src/main/java/com/yahoo/jdisc/core/ActiveContainer.java index 51a84a4a6c6..fbc45f000d2 100644 --- a/jdisc_core/src/main/java/com/yahoo/jdisc/core/ActiveContainer.java +++ b/jdisc_core/src/main/java/com/yahoo/jdisc/core/ActiveContainer.java @@ -17,15 +17,12 @@ import com.yahoo.jdisc.service.ServerProvider; import java.net.URI; import java.util.Map; -import java.util.logging.Logger; /** * @author <a href="mailto:simon@yahoo-inc.com">Simon Thoresen</a> */ public class ActiveContainer extends AbstractResource implements CurrentContainer { - private static final Logger log = Logger.getLogger(ActiveContainer.class.getName()); - private final ContainerTermination termination; private final Injector guiceInjector; private final Iterable<ServerProvider> serverProviders; @@ -67,22 +64,6 @@ public class ActiveContainer extends AbstractResource implements CurrentContaine termination.run(); } - // TODO Get rid of finalizer and use PhantomReference or Java 9 Cleaner instead - @Override - protected void finalize() throws Throwable { - try { - int retainCount = retainCount(); - if (retainCount > 0) { - log.severe("Destructing " + this + " through finalizer since reference count never reached zero. " + - "This is an indication of either a resource leak or invalid use of reference counting. " + - "Retained references as this moment: " + retainCount); - destroy(); - } - } finally { - super.finalize(); - } - } - /** * Make this instance retain a reference to the resource until it is destroyed. */ |