I found a long 13 page thread about this issue but no one really seemed to have the solution:
http://forum.hibernate.org/viewtopic.ph ... t=weblogic
When I redeploy my app about 4 or 5 times the weblogic server instance runs out of memory. This presents a real problem in our development environment where we are reploying many times a day.
As suggested somewhere in the above 13 page thread I created a ServletContextListener and closed my hibernate session factory and I also call the LogFactory.release(classloader) method to release the commons logging factory (mentioned at a link I found in the above 13 page thread).
None of this works, I still get OutOfMemory exceptions after 4 or 5 redeploys. I have tried undeploying the applicaiton first before doing a deploy (I use BEA's supplied wldeploy ANT task for deploy/undeploy).
I simply can't use Hibernate in production with this issue (of course things don't get deployed to production very often but it is still a timebomb waiting to happen).