2 Replies Latest reply: Feb 15, 2013 1:47 PM by 991405 RSS

    oracle.sql.AnyDataFactory ThreadLocal? causing classloader leak

    884077
      I am running a standard Jersey (JAX-RS), Spring, JPA, Hibernate, Oracle application on Tomcat.

      Hot-redeploys to Tomcat 6.0.32 are causing classloader leaks which you can see with the Find Leaks button on the manager page.

      Using jmap and Memory Analyzer Tool, I can see two objects that are keeping the classloader from gc'ing.

      The first is that the Diagnosability MBean is not getting unregistered. That is easy to find and unregister.

      The other is a ThreadLocal in oracle.sql.AnyDataFactory but as I have no code (and a static field for it is not available), I don't see how to clean that up.
      Also the ThreadLocal reporting that Tomcat does doesn't find it which is odd.

      Any thoughts? Are other people seeing this?

      Brian