@Override
  public ServerName randomAssignment(RegionInfo regionInfo, List<ServerName> servers)
    throws IOException {
    // should only have 1 region server in maintenance mode
    assert servers.size() == 1;
    return regionInfo.getTable().isSystemTable() ? servers.get(0) : null;
  }
a balancer which is only used in maintenance mode.
hbase-server/src/main/java/org/apache/hadoop/hbase/master/balancer/MaintenanceLoadBalancer.java