diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/RpcControllerFactory.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/RpcControllerFactory.java index 0dcb22fa5b8..e6d63fac1f1 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/RpcControllerFactory.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/RpcControllerFactory.java @@ -18,15 +18,14 @@ package org.apache.hadoop.hbase.ipc; import java.util.List; - import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.hbase.CellScannable; import org.apache.hadoop.hbase.CellScanner; import org.apache.hadoop.hbase.client.RegionInfo; +import org.apache.hadoop.hbase.util.ReflectionUtils; import org.apache.yetus.audience.InterfaceAudience; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import org.apache.hadoop.hbase.util.ReflectionUtils; /** * Factory to create a {@link HBaseRpcController} @@ -52,16 +51,23 @@ public class RpcControllerFactory { return new HBaseRpcControllerImpl(); } + public HBaseRpcController newController(CellScanner cellScanner) { + return new HBaseRpcControllerImpl(null, cellScanner); + } + public HBaseRpcController newController(RegionInfo regionInfo, CellScanner cellScanner) { return new HBaseRpcControllerImpl(regionInfo, cellScanner); } + public HBaseRpcController newController(final List cellIterables) { + return new HBaseRpcControllerImpl(null, cellIterables); + } + public HBaseRpcController newController(RegionInfo regionInfo, final List cellIterables) { return new HBaseRpcControllerImpl(regionInfo, cellIterables); } - public static RpcControllerFactory instantiate(Configuration configuration) { String rpcControllerFactoryClazz = configuration.get(CUSTOM_CONTROLLER_CONF_KEY,