HBASE-17746 TestSimpleRpcScheduler.testCoDelScheduling is broken

This commit is contained in:
Guanghao Zhang 2017-03-10 15:47:54 +08:00
parent dc84c7b9a7
commit 531598d67f
2 changed files with 3 additions and 4 deletions

View File

@ -85,10 +85,10 @@ public class SimpleRpcScheduler extends RpcScheduler implements ConfigurationObs
callExecutor = new RWQueueRpcExecutor("deafult.RWQ", Math.max(2, handlerCount),
maxQueueLength, priority, conf, server);
} else {
if (RpcExecutor.isFifoQueueType(callQueueType)) {
if (RpcExecutor.isFifoQueueType(callQueueType) || RpcExecutor.isCodelQueueType(callQueueType)) {
callExecutor = new FastPathBalancedQueueRpcExecutor("deafult.FPBQ", handlerCount,
maxQueueLength, priority, conf, server);
} else {
} else {
callExecutor = new BalancedQueueRpcExecutor("deafult.BQ", handlerCount, maxQueueLength,
priority, conf, server);
}

View File

@ -410,8 +410,7 @@ public class TestSimpleRpcScheduler {
@Test
public void testCoDelScheduling() throws Exception {
CoDelEnvironmentEdge envEdge = new CoDelEnvironmentEdge();
envEdge.threadNamePrefixs.add("RpcServer.CodelFPBQ.default.handler");
envEdge.threadNamePrefixs.add("RpcServer.CodelRWQ.default.handler");
envEdge.threadNamePrefixs.add("RpcServer.deafult.FPBQ.Codel.handler");
Configuration schedConf = HBaseConfiguration.create();
schedConf.setInt(RpcScheduler.IPC_SERVER_MAX_CALLQUEUE_LENGTH, 250);