Take the 2-minute tour ×
Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. It's 100% free, no registration required.

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
    
Have you tried any of the Java heap analyzer tools listed under bit.ly/Y1phHO? –  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
1  
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

1 Answer 1

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

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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