Jetty Util : Common Memory Leak Prevention Tooling
Class Summary Class Description AbstractLeakPreventerAbstractLeakPreventer Abstract base class for code that seeks to avoid pinning of webapp classloaders by using the jetty classloader to proactively call the code that pins them (generally pinned as static data members, or as static data members that are daemon threads (which use the context classloader)). AppContextLeakPreventerAppContextLeakPreventer Cause the classloader that is pinned by AppContext.getAppContext() to be a container or system classloader, not a webapp classloader. AWTLeakPreventerAWTLeakPreventer See https://issues.jboss.org/browse/AS7-3733 The java.awt.Toolkit class has a static field that is the default toolkit. DriverManagerLeakPreventerDriverManagerLeakPreventer Cause DriverManager.getCallerClassLoader() to be called, which will pin the classloader.