Hi Mauro, Hmmm... There can be a lots of reasons for memory leaks. I am not aware of any memory leaks in the OpenJPA code at this time, but that doesn't mean that some are not still waiting to be discovered...
First off, the jpql package that you reference is used for parsing the JPQL that is being used by your application. I'd very surpised if this package was the culprit of the memory leak. More than likely, this is due to some references that are not being cleaned up properly. Normally, memory analysis tools will allow you to go "up the stack" and see where the references are coming from. Any other hints in this area? OpenJPA provides a Query Compilation Cache that is on by default. This cache is for caching the parsed aspects of JPQL so that we don't have to parse the same strings over and over again. But, if this cache was getting too large, you would see a different Class referenced in your memory analysis. What version of OpenJPA are you using? There have been various improvements through out the lifetime of OpenJPA related to memory usage, locking, threading, etc that may come into play with your scenario. You mention that you are using Container-managed persistence. Which application server are you using? A common problem with Application-managed persistence is not cleaning up the EntityManagers properly (thus causing memory leaks). I suppose it's possible that the Container-managed persistence you are using has a problem with your scenario. Let's start the conversation and see where it takes us. Kevin On Mon, May 25, 2009 at 5:13 PM, Mauro Flores < [email protected]> wrote: > > Hi, > > I'm getting memory leak in my aplication server. When I use a tool to see > which object has more instances in memory, I find this class in the top > five: org.apache.openjpa.kernel.jpql.JPQL$JJCalls. > > From this information, is it possible to imply that I not working correctly > with JPA api, and this could be the reason of mem leak? > > My EntityManagers are managed by EJB. I don't opened neither close it. > > Thanks for some hint, > > Mauro. > -- > View this message in context: > http://n2.nabble.com/Memory-Leak-and-JJCalls-tp2971921p2971921.html > Sent from the OpenJPA Users mailing list archive at Nabble.com. > >
