Commit 06726e1
committed
[FIX] Fix IllegalThreadStateException in ComponentStarter shutdown hook (#4733)
The UncaughtExceptionHandler in ComponentStarter calls
shutdownHookThread.start(), but this can throw IllegalThreadStateException
if the thread was already started by a prior exception or by the JVM
shutdown sequence. This exception propagates out of the handler, causing
the JVM to print "Exception thrown from the UncaughtExceptionHandler"
on the BookieDeathWatcher thread.
Catch IllegalThreadStateException since it simply means shutdown is
already in progress.1 parent ff7ea0d commit 06726e1
File tree
1 file changed
+6
-1
lines changed- bookkeeper-common/src/main/java/org/apache/bookkeeper/common/component
1 file changed
+6
-1
lines changedLines changed: 6 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
78 | | - | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
79 | 84 | | |
80 | 85 | | |
81 | 86 | | |
| |||
0 commit comments