public abstract class IlrJMXAbstractThreadMonitor
extends java.lang.Object
java.lang.management.ThreadMXBean
instance.ThreadMXBean,
ThreadInfo| Constructor and Description |
|---|
IlrJMXAbstractThreadMonitor() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
createModelFactory() |
boolean |
enableThreadContentionMonitoring()
Call this method to enable the JVM thread contention monitoring.
|
abstract void |
endUsage()
To end usage of a instance of this.
|
IlrClassDescriptionSet |
getBlockingClass(int stackTraceDepth,
java.util.EnumSet<java.lang.Thread.State> threadStates,
long[] excludedThreadIds)
Build or complete the monitoring model.
|
protected abstract void |
initalizeThreadMXBean()
Initialize the
java.lang.management.ThreadMXBean instance. |
void |
reset()
To reset the model.
|
protected abstract void initalizeThreadMXBean()
java.lang.management.ThreadMXBean instance. It is called in constructor.java.lang.RuntimeException - if any exception occurs.protected final void createModelFactory()
public final boolean enableThreadContentionMonitoring()
true if the feature has been enable successfully.ThreadMXBean.isThreadContentionMonitoringSupported(),
ThreadMXBean.setThreadContentionMonitoringEnabled(boolean)public final IlrClassDescriptionSet getBlockingClass(int stackTraceDepth, java.util.EnumSet<java.lang.Thread.State> threadStates, long[] excludedThreadIds)
java.lang.IllegalArgumentException - if stackTraceDepth is inferior or equals to 0.stackTraceDepth - indicates the depth of the stacktrace inside the model built. Should be a positive int
value.threadStates - an enum set containing all the state of threads that we want in the model. For instance
EnumSet.of( Thread.State.BLOCKED)excludedThreadIds - ids of thread that we don't want to monitor.IlrClassDescriptionSet.Thread.Statepublic final void reset()
public abstract void endUsage()
© Copyright IBM Corp. 1987, 2017