Collecting leak detection data with manual heap dumps
Manual heap dumps are captured at your discretion at any time during the profiling run. Capture a heap dump after application warm-up (during which all the class of interest to you are loaded and initialized), and another heap dump after exercising transactions that you suspect of leaking memory.
Prerequisites:
- Agent Controller must be running on the machine on which you are collecting data. For information, refer to the installation guide.
- Create a profiling configuration. Read Getting started: Creating a profiling configuration for run-time problem determination
To collect data using manual heap dumps:
- In the Profiling tab (Overview subtab) of the Profile dialog box, select the Memory Leak Analysis - Manual heap dumps profiling set.
- If you want to adjust the threshold for reporting leak candidates, perform the following steps. The default value is 20. Decreasing the threshold value means that you display more potential leaks.
- Click the Edit button to open the Edit Profiling Set dialog box.
- Select the Automatic Leak Detection profiling type. (Note that when you collect leak detection data, you cannot collect other types of profiling data.)
- Set the threshold to a value between 1 and 99.
- Click the Finish button.
- Click Profile to start your application.
- Click the Capture Heap Dump button
to capture your first heap dump after your application has warmed up. Heap dumps are added in the Profiling Monitor as profiling resources.
- Exercise your application and click the Capture Heap Dump button again to capture a second heap dump. You can now terminate or detach your application, but you can also leave it running and capture additional heap dumps to investigate other parts of your application.
Parent topic
Obtaining heap dumps for memory leak analysis
Related tasks
Generating a list of leak candidates
Related reference
The Leak Candidates view
Automatic Leak Detection page, Edit Profiling Set dialog box
Related information
Getting started: Profiling J2EE applications