Class Overview
This class creates thread dump files in a specified directory. If, for some reason, this Dumper is unable to write to
the target directory, it will simply print the thread dump to err
.
Summary
Public Methods |
String
|
dumpThreads(String directory)
Obtains a JVM thread dump and writes it to a file, if possible.
|
[Expand]
Inherited Methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
|
Public Constructors
Public Methods
public
String
dumpThreads
(String directory)
Obtains a JVM thread dump and writes it to a file, if possible. If writing to a file fails, the thread dump is
written to err
.
Parameters
directory
| the directory where the thread dump will be saved |
Returns
- a String containing the absolute path name of the file that was created, or null if the thread dump was
written to System.err
See Also
- java.lang.management.ThreadMXBean