oldRegionInfo.setOffline(true);
oldRegionInfo.setSplit(true);
// Inform the HRegionServer that the parent HRegion is no-longer online.
this.server.removeFromOnlineRegions(oldRegionInfo);
BatchUpdate update = new BatchUpdate(oldRegionInfo.getRegionName());
update.put(COL_REGIONINFO, Writables.getBytes(oldRegionInfo));
update.put(COL_SPLITA, Writables.getBytes(newRegions[0].getRegionInfo()));
update.put(COL_SPLITB, Writables.getBytes(newRegions[1].getRegionInfo()));
t.commit(update);
// Add new regions to META
for (int i = 0; i < newRegions.length; i++) {
update = new BatchUpdate(newRegions[i].getRegionName());
update.put(COL_REGIONINFO, Writables.getBytes(
newRegions[i].getRegionInfo()));
t.commit(update);
}
// Now tell the master about the new regions