Example #1
0
 /**
  * Updates the location of the specified region to be the specified server.
  *
  * <p>Connects to the specified server which should be hosting the specified catalog region name
  * to perform the edit.
  *
  * @param catalogTracker
  * @param regionInfo region to update location of
  * @param sn Server name
  * @throws IOException In particular could throw {@link java.net.ConnectException} if the server
  *     is down on other end.
  */
 private static void updateLocation(
     final CatalogTracker catalogTracker, HRegionInfo regionInfo, ServerName sn)
     throws IOException {
   Put put = new Put(regionInfo.getRegionName());
   addLocation(put, sn);
   putToCatalogTable(catalogTracker, put);
   LOG.info("Updated row " + regionInfo.getRegionNameAsString() + " with server=" + sn);
 }