public synchronized void deleteFavoredNodesForRegion(RegionInfo regionInfo) {
    List<ServerName> favNodes = getFavoredNodes(regionInfo);
    if (favNodes != null) {
      if (primaryRSToRegionMap.containsKey(favNodes.get(PRIMARY.ordinal()))) {
        primaryRSToRegionMap.get(favNodes.get(PRIMARY.ordinal())).remove(regionInfo);
      }
      if (secondaryRSToRegionMap.containsKey(favNodes.get(SECONDARY.ordinal()))) {
        secondaryRSToRegionMap.get(favNodes.get(SECONDARY.ordinal())).remove(regionInfo);
      }
      if (teritiaryRSToRegionMap.containsKey(favNodes.get(TERTIARY.ordinal()))) {
        teritiaryRSToRegionMap.get(favNodes.get(TERTIARY.ordinal())).remove(regionInfo);
      }
      globalFavoredNodesAssignmentPlan.removeFavoredNodes(regionInfo);
    }
  }
Get the replica count for the servers provided.
<p/>
For each server, replica count includes three counts for primary, secondary and tertiary. If a
server is the primary favored node for 10 regions, secondary for 5 and tertiary for 1, then the
list would be [10, 5, 1]. If the server is newly added to the cluster is not a favored node for
any region, the replica count would be [0, 0, 0].
hbase-balancer/src/main/java/org/apache/hadoop/hbase/favored/FavoredNodesManager.java