You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2019/11/20 17:04:28 UTC

[hbase] 01/02: Add status when fixing hole

This is an automated email from the ASF dual-hosted git repository.

stack pushed a commit to branch branch-2
in repository https://gitbox.apache.org/repos/asf/hbase.git

View the commit online:
https://github.com/apache/hbase/commit/a05cef75c4b33171ab29d89d0fbb0fbbc11d6d39

commit a05cef75c4b33171ab29d89d0fbb0fbbc11d6d39
Author: stack <st...@apache.org>
AuthorDate: Tue Nov 19 09:53:58 2019 -0800

    Add status when fixing hole
    
    TODO: Add region to master memory and region state.
---
 .../src/main/java/org/apache/hadoop/hbase/master/MetaFixer.java    | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/MetaFixer.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/MetaFixer.java
index 3477ec6..5cfa25a 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/MetaFixer.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/MetaFixer.java
@@ -100,10 +100,9 @@ class MetaFixer {
       // If an error here, then we'll have a region in the filesystem but not
       // in hbase:meta (if the below fails). Should be able to rerun the fix.
       // The second call to createRegionDir will just go through. Idempotent.
-      Put put = MetaTableAccessor.makePutFromRegionInfo(ri, HConstants.LATEST_TIMESTAMP);
-      MetaTableAccessor.putsToMetaTable(this.masterServices.getConnection(),
-          Collections.singletonList(put));
-      LOG.info("Fixed hole by adding {}; region is NOT assigned (assign to online).", ri);
+      MetaTableAccessor.addRegionToMeta(this.masterServices.getConnection(), ri);
+      LOG.info("Fixed hole by adding {} in CLOSED state; region NOT assigned (assign to ONLINE).",
+          ri);
     }
   }