hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zhang...@apache.org
Subject [11/50] [abbrv] hbase git commit: HBASE-20015 TestMergeTableRegionsProcedure and TestRegionMergeTransactionOnCluster flakey
Date Thu, 22 Feb 2018 06:59:00 GMT
HBASE-20015 TestMergeTableRegionsProcedure and TestRegionMergeTransactionOnCluster flakey


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/f3ff55a2
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/f3ff55a2
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/f3ff55a2

Branch: refs/heads/HBASE-19064
Commit: f3ff55a2b4bb7a8b4980fdbb5b1f7a8d033631f3
Parents: 68d509b
Author: Michael Stack <stack@apache.org>
Authored: Fri Feb 16 22:59:32 2018 -0800
Committer: Michael Stack <stack@apache.org>
Committed: Sat Feb 17 11:38:26 2018 -0800

----------------------------------------------------------------------
 .../master/assignment/MergeTableRegionsProcedure.java | 14 ++++++++++----
 .../master/assignment/SplitTableRegionProcedure.java  |  1 +
 2 files changed, 11 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/f3ff55a2/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/MergeTableRegionsProcedure.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/MergeTableRegionsProcedure.java
b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/MergeTableRegionsProcedure.java
index 4bccab7..bd41208 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/MergeTableRegionsProcedure.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/MergeTableRegionsProcedure.java
@@ -255,10 +255,16 @@ public class MergeTableRegionsProcedure
         throw new UnsupportedOperationException(this + " unhandled state=" + state);
       }
     } catch (IOException e) {
-      LOG.warn("Error trying to merge regions " + RegionInfo.getShortNameToLog(regionsToMerge)
+
-        " in the table " + getTableName() + " (in state=" + state + ")", e);
-
-      setFailure("master-merge-regions", e);
+      String msg = "Error trying to merge regions " +
+        RegionInfo.getShortNameToLog(regionsToMerge) + " in the table " + getTableName()
+
+           " (in state=" + state + ")";
+      if (!isRollbackSupported(state)) {
+        // We reach a state that cannot be rolled back. We just need to keep retry.
+        LOG.warn(msg, e);
+      } else {
+        LOG.error(msg, e);
+        setFailure("master-merge-regions", e);
+      }
     }
     return Flow.HAS_MORE_STATE;
   }

http://git-wip-us.apache.org/repos/asf/hbase/blob/f3ff55a2/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/SplitTableRegionProcedure.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/SplitTableRegionProcedure.java
b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/SplitTableRegionProcedure.java
index c139566..e898d6a 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/SplitTableRegionProcedure.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/SplitTableRegionProcedure.java
@@ -270,6 +270,7 @@ public class SplitTableRegionProcedure
       } else {
         LOG.error(msg, e);
         setFailure(e);
+        setFailure("master-split-regions", e);
       }
     }
     // if split fails,  need to call ((HRegion)parent).clearSplit() when it is a force split


Mime
View raw message