You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hbase.apache.org by "Xiaolin Ha (Jira)" <ji...@apache.org> on 2019/10/18 08:21:00 UTC

[jira] [Created] (HBASE-23186) Set Fsck thread be daemon and close its OutputStream when master abort

Xiaolin Ha created HBASE-23186:
----------------------------------

             Summary: Set Fsck thread be daemon and close its OutputStream when master abort
                 Key: HBASE-23186
                 URL: https://issues.apache.org/jira/browse/HBASE-23186
             Project: HBase
          Issue Type: Bug
          Components: master
            Reporter: Xiaolin Ha
            Assignee: Xiaolin Ha


HBASE-21072 imported to use HBaseFsck as default in hbase2.
{code:java}
if (this.conf.getBoolean("hbase.write.hbck1.lock.file", true)) {
  HBaseFsck.checkAndMarkRunningHbck(this.conf,
      HBaseFsck.createLockRetryCounterFactory(this.conf).create());
}{code}
But the fsck thread is not daemon,
{code:java}
public static Pair<Path, FSDataOutputStream> checkAndMarkRunningHbck(Configuration conf,
    RetryCounter retryCounter) throws IOException {
  FileLockCallable callable = new FileLockCallable(conf, retryCounter);
  ExecutorService executor = Executors.newFixedThreadPool(1);
...{code}
This will make JVM not exit.

We should set it be daemon and close the dfs output stream when master abort/stop.

 

 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)