[
https://issues.apache.org/jira/browse/HBASE-19954?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16369635#comment-16369635
]
Ted Yu commented on HBASE-19954:
--------------------------------
In the @After method of TestBlockReorder, shutdownMiniCluster() is called.
Clearing shutdown hooks came from this patch:
https://issues.apache.org/jira/secure/attachment/12751805/HDFS-8838-HDFS-7285-20150821.patch#file-6
whose parent JIRA, HDFS-7285, was incorporated into hadoop3.
In patch v3, I separate the 3 subtests into 3 tests since they use different
replication count.
I ran the tests locally, including the new files, which passed.
> ShutdownHook should check whether shutdown hook is tracked by
> ShutdownHookManager
> ---------------------------------------------------------------------------------
>
> Key: HBASE-19954
> URL: https://issues.apache.org/jira/browse/HBASE-19954
> Project: HBase
> Issue Type: Bug
> Reporter: Ted Yu
> Assignee: Ted Yu
> Priority: Major
> Fix For: 2.0.0-beta-2
>
> Attachments: 19954.v1.txt, 19954.v2.txt, 19954.v3.txt
>
>
> Currently ShutdownHook#suppressHdfsShutdownHook() does the following:
> {code}
> synchronized (fsShutdownHooks) {
> boolean isFSCacheDisabled =
> fs.getConf().getBoolean("fs.hdfs.impl.disable.cache", false);
> if (!isFSCacheDisabled &&
> !fsShutdownHooks.containsKey(hdfsClientFinalizer)
> && !ShutdownHookManager.deleteShutdownHook(hdfsClientFinalizer)) {
> {code}
> There is no check that ShutdownHookManager still tracks the shutdown hook,
> leading to potential RuntimeException (as can be observed in hadoop3 Jenkins
> job).
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)