Using Eclipse Memory Analyzer for heap dump file analysis

Source: Internet
Author: User

Introduction: Eclipse Memory Analyzer (MAT) is one of the 33 components of the Eclipse Galileo version of the famous Cross-platform integrated development environment, a feature-rich JAVA heap dump file analysis tool that can help you discover memory vulnerabilities and reduce memory dissipation Consumption. This article mainly describes how to install the configuration Memory Analyzer, and combined with an example, describes how to use MAT to carry out heap dump file analysis, to find the source of memory leaks.

Overview

For a large JAVA application, it's hard to plug all the vulnerabilities, even if we do a lot of good work during the testing phase, many of the problems are exposed in a production environment and are difficult to reproduce in a test environment. The JVM is able to record the partial operating state of the system when the problem occurs and store it in a heap dump (Heap dump) file, which provides an important basis for us to analyze and diagnose the problem.

Typically, memory leak analysis is considered to be a difficult task, typically performed by senior members of the team. However, the MAT (Eclipse Memory Analyzer) We are going to introduce today is considered a "dummy" Heap dump file analysis tool, and you can generate a professional analysis report with a single click of the mouse. Compared with other memory leak analysis tools, MAT is very easy to use and can be implemented in a single key, even novice can use it quickly.

The use of MAT is so easy, you are not also very interested to feel it personally, then the first step we first to install MAT.

Prepare environment and test data

We are using Eclipse Memory Analyzer V0.8,sun JDK 6

Install MAT

Similar to the installation of other plug-ins, MAT supports two installation methods, one is "stand-alone", that is, users do not have to install the Eclipse IDE environment, MAT as a stand-alone Eclipse RCP application, the other is "integrated", that is to say MAT can also be used as ECLI Part of the PSE IDE, integrated with existing development platforms.

The installation of an integrated version requires the help of Update Manager.

As shown in Figure 1, first through the help-> Software Updates ... Start the Software Update Management wizard.

Figure 1. Install plugin First step

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.