1 Reply Latest reply on Sep 2, 2009 2:32 PM by Rafael Ribeiro

    Memory leak of application using hibernate

    Toni Menendez Newbie

      Hello everybody,

      I am developing an application using Jboss 4.0.3SP1 and Hibernate 3.1, and I have lots of problems because my system JVM heap gets full after some minutes of loadtests.

      I have profiled the memory of jboss and I have realized that class org.hibernate.hql.QueryTranslator is instantiating, and instances of the class are never deallocaed from memory ( even after some GC )

      Do you have any idea, what could be the problem ?

        • 1. Re: Memory leak of application using hibernate
          Rafael Ribeiro Novice

          Unless you have something really strong that prevents you from upgrading I'd sincerely suggest you to go to something more recent.
          Lately we faced a memory leak on Hibernate 3.2.1 on WAS (Session id wasnt kept across creation/closing) and upgrading to the latest version fixed.
          You can try to review release notes from all versions after yours (3.1) and see if there were any fixed bugs related to leaking on QueryTranslator then decide on how to upgrade hibernate (at least to the version that fixed your problem) so you avoid much refactoring due to version changes (that I can tell you were not minor).