HBASE-6437 Avoid admin.balance during master initialize
Submitted by:rajesh Reviewed by: Ted git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1377025 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
59232d411f
commit
5f5f22e30d
|
@ -1229,6 +1229,11 @@ Server {
|
|||
}
|
||||
|
||||
public boolean balance() {
|
||||
// if master not initialized, don't run balancer.
|
||||
if (!this.initialized) {
|
||||
LOG.debug("Master has not been initialized, don't run balancer.");
|
||||
return false;
|
||||
}
|
||||
// If balance not true, don't run balancer.
|
||||
if (!this.balanceSwitch) return false;
|
||||
// Do this call outside of synchronized block.
|
||||
|
|
Loading…
Reference in New Issue