HBASE-22715 All scan requests should be handled by scan handler threads in RWQueueRpcExecutor (#393)

Signed-off-by: Andrew Purtell <apurtell@apache.org>

Conflicts:
	hbase-server/src/test/java/org/apache/hadoop/hbase/ipc/TestSimpleRpcScheduler.java
This commit is contained in:
Jeongdae Kim 2019-07-19 16:51:34 +09:00 committed by Andrew Purtell
parent f77baaba3b
commit d88ee0447a
No known key found for this signature in database
GPG Key ID: 8597754DD5365CCD
2 changed files with 2 additions and 7 deletions

View File

@ -229,12 +229,7 @@ public class RWQueueRpcExecutor extends RpcExecutor {
} }
private boolean isScanRequest(final RequestHeader header, final Message param) { private boolean isScanRequest(final RequestHeader header, final Message param) {
if (param instanceof ScanRequest) { return param instanceof ScanRequest;
// The first scan request will be executed as a "short read"
ScanRequest request = (ScanRequest)param;
return request.hasScannerId();
}
return false;
} }
/* /*

View File

@ -362,7 +362,7 @@ public class TestSimpleRpcScheduler {
CallRunner scanCallTask = mock(CallRunner.class); CallRunner scanCallTask = mock(CallRunner.class);
ServerCall scanCall = mock(ServerCall.class); ServerCall scanCall = mock(ServerCall.class);
scanCall.param = ScanRequest.newBuilder().setScannerId(1).build(); scanCall.param = ScanRequest.newBuilder().build();
RequestHeader scanHead = RequestHeader.newBuilder().setMethodName("scan").build(); RequestHeader scanHead = RequestHeader.newBuilder().setMethodName("scan").build();
when(scanCallTask.getRpcCall()).thenReturn(scanCall); when(scanCallTask.getRpcCall()).thenReturn(scanCall);
when(scanCall.getHeader()).thenReturn(scanHead); when(scanCall.getHeader()).thenReturn(scanHead);