Class ToolInvocationLogShutdownHook
java.lang.Object
java.lang.Thread
com.unboundid.ldap.sdk.unboundidds.tools.ToolInvocationLogShutdownHook
- All Implemented Interfaces:
Runnable
This class provides a thread that will be registered as a JVM shutdown hook
for any command-line tool for which invocation logging is to be performed.
If the tool is interrupted by a JVM shutdown (for example, if the JVM
receives a kill signal, if the user presses Control+C, or the tool calls
System.exit) before it can complete naturally, then this shutdown hook thread
will be run to try to ensure that the tool invocation log includes a record
of the abnormal shutdown.
NOTE: This class, and other classes within the
com.unboundid.ldap.sdk.unboundidds package structure, are only
supported for use against Ping Identity, UnboundID, and
Nokia/Alcatel-Lucent 8661 server products. These classes provide support
for proprietary functionality or for external specifications that are not
considered stable or mature enough to be guaranteed to work in an
interoperable way with other types of LDAP servers.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Thread
Thread.Builder, Thread.State, Thread.UncaughtExceptionHandler -
Field Summary
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new instance of this shutdown hook with the provided log details. -
Method Summary
Modifier and TypeMethodDescriptionvoidrun()Logs a completion message indicating that tool processing was interrupted by a JVM shutdown.Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, isVirtual, join, join, join, join, ofPlatform, ofVirtual, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, sleep, start, startVirtualThread, stop, suspend, threadId, toString, yield
-
Constructor Details
-
ToolInvocationLogShutdownHook
Creates a new instance of this shutdown hook with the provided log details.- Parameters:
logDetails- The log details of the tool. It must not benull.
-
-
Method Details