public final class IlrMonitorLocalTool extends IlrMonitorTool
IlrMonitorLocalTool tool = new IlrMonitorLocalTool(20, 10L);
tool.launch();
// Code to monitor ....
tool.printXmlLogInFile("monitor.xml");
IlrJMXLocalThreadMonitor| Constructor and Description |
|---|
IlrMonitorLocalTool(int depth,
long intervalMs)
Constructs the tool with a capability to build the model with a depth of stack trace, and with a given interval
of monitoring.
|
IlrMonitorLocalTool(int depth,
long intervalMs,
java.util.EnumSet<java.lang.Thread.State> threadStates)
Constructs the tool with a capability to build the model with a depth of stack trace, and with a given interval
of monitoring.
|
IlrMonitorLocalTool(int depth,
long intervalMs,
java.util.EnumSet<java.lang.Thread.State> threadStates,
long[] excludedThreadIds)
Constructs the tool with a capability to build the model with a depth of stack trace, and with a given interval
of monitoring.
|
| Modifier and Type | Method and Description |
|---|---|
org.w3c.dom.Document |
getXMLModel()
Returns an instance of
org.w3c.dom.Document that represents the model of thread contention. |
void |
launch()
Calls to this method launch the listener thread and so begins monitoring.
|
void |
print(java.io.PrintWriter writer,
IlrStackElementFilter filter,
boolean xmlFormat)
Prints the model in a serialize format inside a given
PrintWriter. |
printTextLogInFile, printXmlLogInFilepublic IlrMonitorLocalTool(int depth,
long intervalMs)
java.lang.Thread.State.BLOCKED.
Equivalent to call IlrMonitoringLocalTool(depth, intervals, EnumSet.of(Thread.State.BLOCKED))depth - value of stack trace depth. It means the number of stack elements in a stack trace.intervalMs - interval in milliseconds between two snapshotspublic IlrMonitorLocalTool(int depth,
long intervalMs,
java.util.EnumSet<java.lang.Thread.State> threadStates)
EnumSet given will add information in the model built.
Equivalent to call IlrMonitoringLocalTool(depth, intervals, threadStates, null)depth - value of stack trace depth. It means the number of stack elements in a stack trace.intervalMs - interval in milliseconds between two snapshotsthreadStates - EnumSet of thread state that should be monitored.public IlrMonitorLocalTool(int depth,
long intervalMs,
java.util.EnumSet<java.lang.Thread.State> threadStates,
long[] excludedThreadIds)
EnumSet and whose id is not contained inside the excluded thread ids
long array given will add information in the model built.depth - value of stack trace depth. It means the number of stack elements in a stack trace.intervalMs - interval in milliseconds between two snapshotsthreadStates - EnumSet of thread state that should be monitored.excludedThreadIds - array of long of thread ids that shouldn't be monitored.public void launch()
print method if needed. But the model will be reset.launch in class IlrMonitorToolpublic void print(java.io.PrintWriter writer,
IlrStackElementFilter filter,
boolean xmlFormat)
PrintWriter. Calls to this method stops the
listener thread.print in class IlrMonitorToolwriter - a instance of PrintWriterfilter - instance of IlrStackElementFilter. Could be null.xmlFormat - true if XML format serialization is wanted.public org.w3c.dom.Document getXMLModel()
org.w3c.dom.Document that represents the model of thread contention. Calls to
this methods will stop the listener thread.getXMLModel in class IlrMonitorTool© Copyright IBM Corp. 1987, 2017