|
Quick Lists
|
|
Bug ID:
|
4211929
|
|
Votes
|
1
|
|
Synopsis
|
It would be cool if application could trigger a heap dump
|
|
Category
|
java:monitoring
|
|
Reported Against
|
1.2
, 1.3.1
|
|
Release Fixed
|
|
|
State
|
11-Closed, duplicate of 6283436,
request for enhancement
|
|
Priority:
|
5-Very Low
|
|
Related Bugs
|
4628285
,
6173612
|
|
Submit Date
|
16-FEB-1999
|
|
Description
|
It would be useful if the application being debugged could trigger a JVMPI
heap dump. It might be the case that a certain point in the program's
execution has a particularly interesting heap topology. A developer debugging
such an application might find it useful to programmatically trigger a dump
at such a point, by calling a private, VM-specific API (like
sun.debug.jvmpi.Mumble.triggerHeapDump()).
Posted Date : 2005-11-21 14:46:23.0
|
|
Work Around
|
N/A
|
|
Evaluation
|
This is already possible using the dumpHeap operation on the HotSpotDiagnosticMXBean.
Posted Date : 2005-11-21 14:46:23.0
As noted, this is possible in mustang - here's a sample code fragment to demonstrate how an application can create a heap dump of its own heap:
import java.lang.management.ManagementFactory;
import javax.management.ObjectName;
import javax.management.MBeanServer;
:
MBeanServer mbs = ManagementFactory.getPlatformMBeanServer();
ObjectName oname = new ObjectName("com.sun.management:type=HotSpotDiagnostic");
Object[] params = { "heap.bin" };
String[] sigs= { "java.lang.String" };
mbs.invoke(oname, "dumpHeap", params, sigs);
The HotSpotDiagnosticMXBean was added via 6283436 so I'll this RFE as a dup.
Posted Date : 2005-12-20 15:53:25.0
|
|
Comments
|
PLEASE NOTE: JDK6 is formerly known as Project Mustang
|
|
|
 |