Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Criteria.list() hanging after a few runs

 
Saurabh Asthana
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have created a criteria object and used projection to get the desired column names.
I have
List alTestResult = criteria.list();

this runs fine for about 2-3 times after which it hangs.
Could you advice me what can be done to prevent this?
Thanks,
Bitz
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is your JVM running out of memory?
 
Saurabh Asthana
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It might be a JVM issue.
Even if it is then what could be the solution for it?
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So, is it a memory issue? No sense trying to solve the wrong problem. How much memory have you given your JVM and how much is it using?
 
Ketan Jambhekar
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you closed your hibernate session after criteria.list() ?
This could happen if your are managing the session yourself.
 
Saurabh Asthana
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Paul,
I have no idea about the memory allocation.Can you tell me how to find it out?
I tried the same program on different computers, and everywhere i faced the same problem.
so how do i find how much memory is being used where?
Thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic