use of org.apache.hadoop.hbase.util.PairOfSameType in project hbase by apache.
the class TestRegionMergeTransactionOnCluster method requestMergeRegion.
private PairOfSameType<HRegionInfo> requestMergeRegion(HMaster master, TableName tablename, int regionAnum, int regionBnum) throws Exception {
List<Pair<HRegionInfo, ServerName>> tableRegions = MetaTableAccessor.getTableRegionsAndLocations(TEST_UTIL.getConnection(), tablename);
HRegionInfo regionA = tableRegions.get(regionAnum).getFirst();
HRegionInfo regionB = tableRegions.get(regionBnum).getFirst();
ADMIN.mergeRegionsAsync(regionA.getEncodedNameAsBytes(), regionB.getEncodedNameAsBytes(), false);
return new PairOfSameType<>(regionA, regionB);
}
Aggregations