[ 
https://issues.apache.org/jira/browse/KARAF-4687?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15452685#comment-15452685
 ] 

Grzegorz Grzybek commented on KARAF-4687:
-----------------------------------------

PR (I'm aware that this may be not accepted): 
https://github.com/apache/karaf/pull/235

> ClassLoader leak with java.lang.Exception and karaf.exception library
> ---------------------------------------------------------------------
>
>                 Key: KARAF-4687
>                 URL: https://issues.apache.org/jira/browse/KARAF-4687
>             Project: Karaf
>          Issue Type: Bug
>    Affects Versions: 2.4.4, 4.0.6, 3.0.8
>            Reporter: Grzegorz Grzybek
>
> Here's much worse leak I found in JVisualVM:
> {noformat}
> this     - value: org.apache.felix.framework.BundleWiringImpl #1
>  <- m_wiring     - class: 
> org.apache.felix.framework.BundleWiringImpl$BundleClassLoaderJava5, value: 
> org.apache.felix.framework.BundleWiringImpl #1
>   <- <classLoader>     - class: org.ops4j.pax.logging.slf4j.Slf4jLogger, 
> value: org.apache.felix.framework.BundleWiringImpl$BundleClassLoaderJava5 #1
>    <- <class>     - class: org.ops4j.pax.logging.slf4j.Slf4jLogger, value: 
> org.ops4j.pax.logging.slf4j.Slf4jLogger class Slf4jLogger
>     <- LOGGER     - class: 
> org.apache.karaf.features.internal.FeaturesServiceImpl, value: 
> org.ops4j.pax.logging.slf4j.Slf4jLogger #3
>      <- [19]     - class: java.lang.Class[], value: 
> org.apache.karaf.features.internal.FeaturesServiceImpl class 
> FeaturesServiceImpl
>       <- classContext     - class: org.apache.xerces.impl.XMLEntityScanner$1, 
> value: java.lang.Class[] #23
>        <- END_OF_DOCUMENT_ENTITY (sticky class)     - class: 
> org.apache.xerces.impl.XMLEntityScanner, value: 
> org.apache.xerces.impl.XMLEntityScanner$1 #1
> {noformat}
> and
> {noformat}
> this     - value: org.apache.felix.framework.BundleWiringImpl #18
>  <- m_wiring     - class: 
> org.apache.felix.framework.BundleWiringImpl$BundleClassLoaderJava5, value: 
> org.apache.felix.framework.BundleWiringImpl #18
>   <- <classLoader>     - class: io.fabric8.api.scr.ValidatingReference, 
> value: org.apache.felix.framework.BundleWiringImpl$BundleClassLoaderJava5 #16
>    <- <class>     - class: io.fabric8.api.scr.ValidatingReference, value: 
> io.fabric8.api.scr.ValidatingReference class ValidatingReference
>     <- curator     - class: 
> io.fabric8.zookeeper.curator.CuratorFrameworkLocator, value: 
> io.fabric8.api.scr.ValidatingReference #1
>      <- [140]     - class: java.lang.Object[], value: 
> io.fabric8.zookeeper.curator.CuratorFrameworkLocator class 
> CuratorFrameworkLocator
>       <- elementData     - class: java.util.Vector, value: java.lang.Object[] 
> #3790
>        <- classes     - class: 
> org.apache.felix.framework.BundleWiringImpl$BundleClassLoaderJava5, value: 
> java.util.Vector #120
>         <- <classLoader>     - class: 
> io.fabric8.zookeeper.curator.ManagedCuratorFramework$State, value: 
> org.apache.felix.framework.BundleWiringImpl$BundleClassLoaderJava5 #15
>          <- [93]     - class: java.lang.Class[], value: 
> io.fabric8.zookeeper.curator.ManagedCuratorFramework$State class 
> ManagedCuratorFramework$State
>           <- classContext     - class: 
> org.eclipse.jgit.errors.StopWalkException, value: java.lang.Class[] #946
>            <- INSTANCE     - class: 
> org.eclipse.jgit.errors.StopWalkException, value: 
> org.eclipse.jgit.errors.StopWalkException #1
>             <- [332]     - class: java.lang.Object[], value: 
> org.eclipse.jgit.errors.StopWalkException class StopWalkException
>              <- elementData     - class: java.util.Vector, value: 
> java.lang.Object[] #3772
>               <- classes     - class: 
> org.apache.felix.framework.BundleWiringImpl$BundleClassLoaderJava5, value: 
> java.util.Vector #119
>                <- <classLoader>     - class: org.eclipse.jgit.nls.NLS, value: 
> org.apache.felix.framework.BundleWiringImpl$BundleClassLoaderJava5 #14
>                 <- <class>     - class: org.eclipse.jgit.nls.NLS, value: 
> org.eclipse.jgit.nls.NLS class NLS
>                  <- value     - class: 
> java.lang.ThreadLocal$ThreadLocalMap$Entry, value: org.eclipse.jgit.nls.NLS #1
>                   <- [11]     - class: 
> java.lang.ThreadLocal$ThreadLocalMap$Entry[], value: 
> java.lang.ThreadLocal$ThreadLocalMap$Entry #144
>                    <- table     - class: 
> java.lang.ThreadLocal$ThreadLocalMap, value: 
> java.lang.ThreadLocal$ThreadLocalMap$Entry[] #1
>                     <- inheritableThreadLocals (thread object)     - class: 
> java.lang.Thread, value: java.lang.ThreadLocal$ThreadLocalMap #2
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to