Revert "HBASE-16209 addendum fix region move delay"

This reverts commit c46f56b382.
This commit is contained in:
zhangduo 2016-08-01 15:52:25 +08:00
parent c46f56b382
commit 51c8c1891a
2 changed files with 10 additions and 6 deletions

View File

@ -3408,7 +3408,7 @@ public class AssignmentManager extends ZooKeeperListener {
return true;
}
public void invokeAssign(HRegionInfo regionInfo) {
void invokeAssign(HRegionInfo regionInfo) {
invokeAssign(regionInfo, true);
}
@ -3421,6 +3421,12 @@ public class AssignmentManager extends ZooKeeperListener {
new AssignCallable(this, regionInfo, true)), sleepMillis, TimeUnit.MILLISECONDS);
}
public void invokeAssignLaterOnFailure(HRegionInfo regionInfo) {
long sleepTime = backoffPolicy.getBackoffTime(retryConfig,
failedOpenTracker.get(regionInfo.getEncodedName()).get());
invokeAssignLater(regionInfo, sleepTime);
}
void invokeUnAssign(HRegionInfo regionInfo) {
threadPoolExecutorService.submit(new UnAssignCallable(this, regionInfo));
}
@ -4492,10 +4498,8 @@ public class AssignmentManager extends ZooKeeperListener {
}
private class DelayedAssignCallable implements Runnable {
private final Callable<?> callable;
public DelayedAssignCallable(Callable<?> callable) {
Callable callable;
public DelayedAssignCallable(Callable callable) {
this.callable = callable;
}

View File

@ -103,6 +103,6 @@ public class ClosedRegionHandler extends EventHandler implements TotesHRegionInf
regionInfo, RegionState.State.CLOSED);
// This below has to do w/ online enable/disable of a table
assignmentManager.removeClosedRegion(regionInfo);
assignmentManager.invokeAssign(regionInfo);
assignmentManager.invokeAssignLaterOnFailure(regionInfo);
}
}