Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My application is causing heap thrashing. I have the heap dump but I don't know how and where should I start to look for problems?

This is a 6 GB dump. Please recommend some suitable heap analysis software?

share|improve this question

closed as off-topic by user246, Kate Paulk, Bruce McLeod Mar 26 '15 at 4:49

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions about software development unrelated to testing are off-topic here, but can be asked on Stack Overflow." – user246, Kate Paulk, Bruce McLeod
If this question can be reworded to fit the rules in the help center, please edit the question.

Have you tried any of the Java heap analyzer tools listed under – user246 Jan 24 '13 at 18:54
Thanks. I started with JProfiler but it was getting stuck while loading the heap. Now, I am using Eclipse MAT. I thought it is good to ask, as some tools can be more optimal for high scale. – Asad Iqbal Jan 24 '13 at 18:57
Any chance you could reproduce the problem with a smaller maximum heap size? – user246 Jan 24 '13 at 19:11
The issue was identified in a production environment, and I didn't know the specific user input. After some investigation using Eclipse MAT, it seemed that one thread was holding to a HashMap for maintaining context. And one user-input processor (one of many handlers which process user input) had 800,000 objects of one class in that map. For now, I handed over the problem to author of that class. Either, it was a very big input which should be stopped before it enters our system OR we need to change design in that handler. – Asad Iqbal Jan 25 '13 at 22:47

Can I suggest using techniques to reduce heap size at compile-time or runtime in order to force this situation to reproduce on smaller scale testing? I used to do this many years ago on an embedded platform with a lot of success, although lately it's not that easy to do without special work if you are using Windows platform. Hope this helps.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.