|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Thread jgroup.util.ThreadMonitor
public class ThreadMonitor
Monitor threads to detect thread failures, and perform corrective action in case some thread has crashed.
This class is helpful with respect to debugging deadlock problems, especially
when DUMP_ALL_THREADS
is set to true. This will, at regular
intervals, dump the stack trace of all threads allowing the developer to
identify threads that might have entered into a deadlock situation awaiting
a lock being held by another thread.
This class requires JDK 5.0, but is not mandatory for general use of Jgroup/ARM, and as such use of this class may be disabled.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.lang.Thread |
---|
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler |
Field Summary |
---|
Fields inherited from class java.lang.Thread |
---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Method Summary | |
---|---|
static void |
add(java.lang.Thread thread)
Add the given thread to the monitor. |
static void |
dumpAllThreads()
|
static void |
remove(java.lang.Thread thread)
Remove the given thread from being monitored. |
void |
run()
|
Methods inherited from class java.lang.Thread |
---|
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public static void add(java.lang.Thread thread)
public static void remove(java.lang.Thread thread)
public static void dumpAllThreads()
public void run()
run
in interface java.lang.Runnable
run
in class java.lang.Thread
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |