diff --git a/CHANGES.txt b/CHANGES.txt index a32e330988e..b01697b5b35 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -676,6 +676,7 @@ Release 0.90.0 - Unreleased HBASE-3216 Move HBaseFsck from client to util HBASE-3219 Split parents are reassigned on restart and on disable/enable HBASE-3222 Regionserver region listing in UI is no longer ordered + HBASE-3221 Race between splitting and disabling IMPROVEMENTS diff --git a/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java b/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java index e14aab87342..83223db0c3b 100644 --- a/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java +++ b/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java @@ -1620,6 +1620,16 @@ public class AssignmentManager extends ZooKeeperListener { regionOffline(parent); regionOnline(a, hsi); regionOnline(b, hsi); + + // There's a possibility that the region was splitting while a user asked + // the master to disable, we need to make sure we close those regions in + // that case. This is not racing with the region server itself since RS + // report is done after the split transaction completed. + if (this.zkTable.isDisablingOrDisabledTable( + parent.getTableDesc().getNameAsString())) { + unassign(a); + unassign(b); + } } /**