Java 类org.apache.hadoop.hbase.TestMetaTableAccessor 实例源码

项目:ditb    文件:TestRegionReplicas.java   
/** Tests that the meta location is saved for secondary regions */
@Test(timeout = 60000)
public void testRegionReplicaUpdatesMetaLocation() throws Exception {
  openRegion(HTU, getRS(), hriSecondary);
  Table meta = null;
  try {
    meta = HTU.getConnection().getTable(TableName.META_TABLE_NAME);
    TestMetaTableAccessor.assertMetaLocation(meta, hriPrimary.getRegionName()
      , getRS().getServerName(), -1, 1, false);
  } finally {
    if (meta != null ) meta.close();
    closeRegion(HTU, getRS(), hriSecondary);
  }
}
项目:pbase    文件:TestRegionReplicas.java   
/** Tests that the meta location is saved for secondary regions */
@Test(timeout = 60000)
public void testRegionReplicaUpdatesMetaLocation() throws Exception {
  openRegion(hriSecondary);
  Table meta = null;
  try {
    meta = new HTable(HTU.getConfiguration(), TableName.META_TABLE_NAME);
    TestMetaTableAccessor.assertMetaLocation(meta, hriPrimary.getRegionName()
      , getRS().getServerName(), -1, 1, false);
  } finally {
    if (meta != null ) meta.close();
    closeRegion(hriSecondary);
  }
}
项目:hbase    文件:TestRegionReplicas.java   
/** Tests that the meta location is saved for secondary regions */
@Test(timeout = 60000)
public void testRegionReplicaUpdatesMetaLocation() throws Exception {
  openRegion(HTU, getRS(), hriSecondary);
  Table meta = null;
  try {
    meta = HTU.getConnection().getTable(TableName.META_TABLE_NAME);
    TestMetaTableAccessor.assertMetaLocation(meta, hriPrimary.getRegionName()
      , getRS().getServerName(), -1, 1, false);
  } finally {
    if (meta != null ) meta.close();
    closeRegion(HTU, getRS(), hriSecondary);
  }
}