Search in sources :

Example 1 with WarmupRegionRequest

use of org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.WarmupRegionRequest in project hbase by apache.

the class ProtobufUtil method warmupRegion.

/**
   * A helper to warmup a region given a region name
   * using admin protocol
   *
   * @param admin
   * @param regionInfo
   *
   */
public static void warmupRegion(final RpcController controller, final AdminService.BlockingInterface admin, final HRegionInfo regionInfo) throws IOException {
    try {
        WarmupRegionRequest warmupRegionRequest = RequestConverter.buildWarmupRegionRequest(regionInfo);
        admin.warmupRegion(controller, warmupRegionRequest);
    } catch (ServiceException e) {
        throw getRemoteException(e);
    }
}
Also used : ServiceException(org.apache.hadoop.hbase.shaded.com.google.protobuf.ServiceException) WarmupRegionRequest(org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.WarmupRegionRequest)

Aggregations

ServiceException (org.apache.hadoop.hbase.shaded.com.google.protobuf.ServiceException)1 WarmupRegionRequest (org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.WarmupRegionRequest)1