Recommendations for a heap analysis tool for Java? [closed]
开发者_运维知识库
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this questionList your favorite heap analysis tools (e.g. jprofiler, jmap, ...). Let's keep it one tool per answer, with a short list of pros and cons for each tool.
Eclipse Memory analyzer http://www.eclipse.org/mat/
- Support for multiple JVMs
- Help with identifying sources for memory leaks (see http://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/6856)
- Open source and actively developed by major vendors (SAP and IBM)
- Part of Galileo release of Eclipse
Consider Java VisualVM, jvisualvm
, included with the JDK. A pathologic Swing program is examined here. For a more recent perspective, see the Monitoring and Management Guide: Using JConsole regarding jconsole
, also included with the JDK.
YourKit : http://www.yourkit.com/
Pros:
- The interface is clean and it's fast
- It opened a large 5-gig heap dump where jProfiler grined to a halt. And it only needed 1-2 gigs of JVM ram to do so.
Cons: Of course... it's not free :(
BHeapSampler http://dr-brenschede.de/bheapsampler/
- generates a class-level heap-graph as a really intuitive display of the dominant memory structures
- can process really large heap dumps
- command-line tool, usable on server side without transfering the dump to the developer's desk
精彩评论