Class GCThreadLeakPreventer

  • All Implemented Interfaces:
    LifeCycle

    @Deprecated
    public class GCThreadLeakPreventer
    extends AbstractLeakPreventer
    Deprecated.
    fixed in jdvm 9b130, see https://bugs.java.com/bugdatabase/view_bug.do?bug_id=JDK-8157570
    GCThreadLeakPreventer Prevents a call to sun.misc.GC.requestLatency pinning a webapp classloader by calling it with a non-webapp classloader. The problem appears to be that when this method is called, a daemon thread is created which takes the context classloader. A known caller of this method is the RMI impl. See http://stackoverflow.com/questions/6626680/does-java-garbage-collection-log-entry-full-gc-system-mean-some-class-called This preventer will start the thread with the longest possible interval, although subsequent calls can vary that. Recommend to only use this class if you're doing RMI. Inspired by Tomcat JreMemoryLeakPrevention.