Class VMControlImpl
java.lang.Object
com.ibm.java.diagnostics.healthcenter.api.vmcontrol.impl.VMControlImpl
- All Implemented Interfaces:
com.ibm.java.diagnostics.common.datamodel.data.DataListener,VMControl
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionVMControlImpl(com.ibm.java.diagnostics.healthcenter.impl.marshalling.MarshallerImpl marshallerInstance) -
Method Summary
Modifier and TypeMethodDescriptionvoidTriggers the collection of the class histogram data.voiddataChanged(com.ibm.java.diagnostics.common.datamodel.data.DataChangedEvent event) booleanReturns whether classes data collection is enabled.booleanReturns whether GC data collection is enabled.booleanReturns whether IO data collection is enabled.booleanReturns whether locking data collection is enabled.booleanReturns whether native memory data collection is enabled.booleanReturns whether profiling data collection is enabled.booleanReturns whether threads data collection is enabled.voidsetCallStackCollectionEnabled(boolean value) Enables the collection of call stacks for sampled object allocation events.voidsetClassesDataCollectionEnabled(boolean value) Turns classes data collection on or off.voidsetGCDataCollectionEnabled(boolean value) Turns GC data collection on or off.voidsetIODataCollectionEnabled(boolean value) Turns IO data collection on or off.voidsetLockingDataCollectionEnabled(boolean value) Turns locking data collection on or off.voidsetMaxStackDepth(int depth) Sets the maximum number of stack entries to collect for each event.voidsetNativeMemoryDataCollectionEnabled(boolean value) Turns native memory data collection on or off.voidsetObjectAllocationsEnabled(long lowValue) Enables the collection of object allocation data for objects above a specified size.voidsetObjectAllocationsEnabled(long lowThreshold, long highThreshold) Enables the collection of object allocation data for objects within a specified size range.voidsetProfilingDataCollectionEnabled(boolean value) Turns profiling data collection on or off.voidsetThreadDataCollectionEnabled(boolean value) Turns thread data collection on or off.voidsetThreadStackDepth(int depth) Sets the maximum number of stack entries to collect for each thread.voidsetTracePointEnabled(String tracePointID, boolean value) Turns individual trace points on or off.voidsetVerboseGCCollectionEnabled(boolean value) Turns the writing of verbose garbage collection data to a file on or off.booleanTriggers a heap dump in the running virtual machine.booleanTriggers a Java dump in the running virtual machine.booleanTriggers a system dump in the running virtual machine.
-
Constructor Details
-
VMControlImpl
public VMControlImpl(com.ibm.java.diagnostics.healthcenter.impl.marshalling.MarshallerImpl marshallerInstance)
-
-
Method Details
-
dataChanged
public void dataChanged(com.ibm.java.diagnostics.common.datamodel.data.DataChangedEvent event) - Specified by:
dataChangedin interfacecom.ibm.java.diagnostics.common.datamodel.data.DataListener
-
setObjectAllocationsEnabled
public void setObjectAllocationsEnabled(long lowThreshold, long highThreshold) Description copied from interface:VMControlEnables the collection of object allocation data for objects within a specified size range.- Specified by:
setObjectAllocationsEnabledin interfaceVMControl- Parameters:
lowThreshold- the minimum size (in bytes) of the objects to collect data on.highThreshold- the maximum size (in bytes) of the objects to collect data on.
-
setObjectAllocationsEnabled
public void setObjectAllocationsEnabled(long lowValue) Description copied from interface:VMControlEnables the collection of object allocation data for objects above a specified size.- Specified by:
setObjectAllocationsEnabledin interfaceVMControl- Parameters:
lowValue- the minimum size (in bytes) of the objects to collect data on.
-
setVerboseGCCollectionEnabled
public void setVerboseGCCollectionEnabled(boolean value) Description copied from interface:VMControlTurns the writing of verbose garbage collection data to a file on or off. The name of the file that is created is verbosegc_process_id_n.log, where process_id is the process ID of the monitored JVM, and n is a sequence number. The file is saved in a directory that is local to the monitored JVM specified by thecom.ibm.java.diagnostics.healthcenter.output.folderproperty. If this property is not set, the file is saved in the directory that is specified by theuser.dirsystem property.- Specified by:
setVerboseGCCollectionEnabledin interfaceVMControl- Parameters:
value- whether collection is on or off. *
-
triggerHeapDump
public boolean triggerHeapDump()Description copied from interface:VMControlTriggers a heap dump in the running virtual machine. A heap dump provides a view of memory objects on the Java heap, and is used for memory analysis.- Specified by:
triggerHeapDumpin interfaceVMControl- Returns:
trueif the trigger command was successfully sent to the virtual machine,falseif the command failed.
-
triggerJavaDump
public boolean triggerJavaDump()Description copied from interface:VMControlTriggers a Java dump in the running virtual machine. A Java dump is also known as a thread dump of the Java core. The Java dump is used for viewing the thread activity inside the JVM at a given time.- Specified by:
triggerJavaDumpin interfaceVMControl- Returns:
trueif the trigger command was successfully sent to the virtual machine,falseif the command failed.
-
triggerSystemDump
public boolean triggerSystemDump()Description copied from interface:VMControlTriggers a system dump in the running virtual machine. A system dump is also known as a core dump. System dump creation involves dumping the entire address space, and can therefore produce very large dumps, and take some time to complete.- Specified by:
triggerSystemDumpin interfaceVMControl- Returns:
trueif the trigger command was successfully sent to the virtual machine,falseif the command failed.
-
setGCDataCollectionEnabled
public void setGCDataCollectionEnabled(boolean value) Description copied from interface:VMControlTurns GC data collection on or off. By default, GC data collection is on. Turning this data off can reduce the amount of data generated by the virtual machine that is running the monitored application, and as a result, can reduce the overhead of monitoring an application with the Health Center.- Specified by:
setGCDataCollectionEnabledin interfaceVMControl- Parameters:
value- whether the collection is on or off.
-
setClassesDataCollectionEnabled
public void setClassesDataCollectionEnabled(boolean value) Description copied from interface:VMControlTurns classes data collection on or off. By default, classes data collection is on. Turning this data off can reduce the amount of data generated by the virtual machine that is running the monitored application, and as a result, can reduce the overhead of monitoring an application with the Health Center.- Specified by:
setClassesDataCollectionEnabledin interfaceVMControl- Parameters:
value- whether the collection is on or off.
-
setIODataCollectionEnabled
public void setIODataCollectionEnabled(boolean value) Description copied from interface:VMControlTurns IO data collection on or off. By default, IO data collection is on. Turning this data off can reduce the amount of data generated by the virtual machine that is running the monitored application, and as a result, can reduce the overhead of monitoring an application with the Health Center.- Specified by:
setIODataCollectionEnabledin interfaceVMControl- Parameters:
value- whether the collection is on or off.
-
setLockingDataCollectionEnabled
public void setLockingDataCollectionEnabled(boolean value) Description copied from interface:VMControlTurns locking data collection on or off. By default, locking data collection is on. Turning this data off can reduce the amount of data generated by the virtual machine that is running the monitored application, and as a result, can reduce the overhead of monitoring an application with the Health Center.- Specified by:
setLockingDataCollectionEnabledin interfaceVMControl- Parameters:
value- whether the collection is on or off.
-
setNativeMemoryDataCollectionEnabled
public void setNativeMemoryDataCollectionEnabled(boolean value) Description copied from interface:VMControlTurns native memory data collection on or off. By default, native memory data collection is on. Turning this data off can reduce the amount of data generated by the virtual machine that is running the monitored application, and as a result, can reduce the overhead of monitoring an application with the Health Center.- Specified by:
setNativeMemoryDataCollectionEnabledin interfaceVMControl- Parameters:
value- whether the collection is on or off.
-
setProfilingDataCollectionEnabled
public void setProfilingDataCollectionEnabled(boolean value) Description copied from interface:VMControlTurns profiling data collection on or off. By default, profiling data collection is on. Turning this data off can reduce the amount of data generated by the virtual machine that is running the monitored application, and as a result, can reduce the overhead of monitoring an application with the Health Center.- Specified by:
setProfilingDataCollectionEnabledin interfaceVMControl- Parameters:
value- whether the collection is on or off.
-
setThreadDataCollectionEnabled
public void setThreadDataCollectionEnabled(boolean value) Description copied from interface:VMControlTurns thread data collection on or off. By default, thread data collection is on. Turning this data off can reduce the amount of data generated by the virtual machine that is running the monitored application, and as a result, can reduce the overhead of monitoring an application with the Health Center.- Specified by:
setThreadDataCollectionEnabledin interfaceVMControl- Parameters:
value- whether the collection is on or off.
-
setTracePointEnabled
Description copied from interface:VMControlTurns individual trace points on or off.- Specified by:
setTracePointEnabledin interfaceVMControl- Parameters:
tracePointID- the ID of the trace point to enable or disable.value- whether the trace point is on or off.- Throws:
HealthCenterException- if the call is unsuccessful.
-
setCallStackCollectionEnabled
public void setCallStackCollectionEnabled(boolean value) Description copied from interface:VMControlEnables the collection of call stacks for sampled object allocation events.- Specified by:
setCallStackCollectionEnabledin interfaceVMControl- Parameters:
value- whether the collection is on or off.
-
setMaxStackDepth
public void setMaxStackDepth(int depth) Description copied from interface:VMControlSets the maximum number of stack entries to collect for each event.- Specified by:
setMaxStackDepthin interfaceVMControl- Parameters:
depth- the maximum number of stack entries.
-
isGCDataCollectionEnabled
public boolean isGCDataCollectionEnabled()Description copied from interface:VMControlReturns whether GC data collection is enabled.- Specified by:
isGCDataCollectionEnabledin interfaceVMControl- Returns:
- boolean.
-
isIODataCollectionEnabled
public boolean isIODataCollectionEnabled()Description copied from interface:VMControlReturns whether IO data collection is enabled.- Specified by:
isIODataCollectionEnabledin interfaceVMControl- Returns:
- boolean.
-
isClassesDataCollectionEnabled
public boolean isClassesDataCollectionEnabled()Description copied from interface:VMControlReturns whether classes data collection is enabled.- Specified by:
isClassesDataCollectionEnabledin interfaceVMControl- Returns:
- boolean.
-
isLockingDataCollectionEnabled
public boolean isLockingDataCollectionEnabled()Description copied from interface:VMControlReturns whether locking data collection is enabled.- Specified by:
isLockingDataCollectionEnabledin interfaceVMControl- Returns:
- boolean.
-
isNativeMemoryDataCollectionEnabled
public boolean isNativeMemoryDataCollectionEnabled()Description copied from interface:VMControlReturns whether native memory data collection is enabled.- Specified by:
isNativeMemoryDataCollectionEnabledin interfaceVMControl- Returns:
- boolean.
-
isProfilingDataCollectionEnabled
public boolean isProfilingDataCollectionEnabled()Description copied from interface:VMControlReturns whether profiling data collection is enabled.- Specified by:
isProfilingDataCollectionEnabledin interfaceVMControl- Returns:
- boolean.
-
isThreadsDataCollectionEnabled
public boolean isThreadsDataCollectionEnabled()Description copied from interface:VMControlReturns whether threads data collection is enabled.- Specified by:
isThreadsDataCollectionEnabledin interfaceVMControl- Returns:
- boolean.
-
collectClassHistogramData
Description copied from interface:VMControlTriggers the collection of the class histogram data. For every class loaded, this process collects the number of instances of that class, and the total amount of memory that is used by those instances.- Specified by:
collectClassHistogramDatain interfaceVMControl- Throws:
HealthCenterNotSupportedException
-
setThreadStackDepth
public void setThreadStackDepth(int depth) Description copied from interface:VMControlSets the maximum number of stack entries to collect for each thread. Setting this to zero will turn off thread stack collection.- Specified by:
setThreadStackDepthin interfaceVMControl- Parameters:
depth- the maximum number of stack entries required.
-