Package org.apache.hadoop.hbase.ipc
Class TestServerCall
java.lang.Object
org.apache.hadoop.hbase.ipc.TestServerCall
Test for ServerCall IOException handling in setResponse method.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final HBaseClassTestRule
private org.apache.hadoop.conf.Configuration
private org.apache.hadoop.hbase.shaded.protobuf.generated.RPCProtos.RequestHeader
private static final org.slf4j.Logger
private InetAddress
private org.apache.hadoop.hbase.io.ByteBuffAllocator
private org.apache.hadoop.hbase.ipc.CellBlockBuilder
private org.apache.hadoop.hbase.ipc.NettyServerRpcConnection
private org.apache.hbase.thirdparty.com.google.protobuf.Descriptors.MethodDescriptor
private org.apache.hbase.thirdparty.com.google.protobuf.Message
private org.apache.hbase.thirdparty.com.google.protobuf.BlockingService
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
setUp()
void
Test normal response creation to ensure our changes don't break the normal flow.void
Test the case where both normal response creation and error response creation fail with IOException.void
Test that when IOException occurs during response creation in setResponse, an error response is created and sent to the client instead of leaving the response as null.
-
Field Details
-
CLASS_RULE
-
LOG
-
conf
-
mockConnection
-
header
-
mockParam
-
mockAllocator
-
mockCellBlockBuilder
-
mockAddr
-
mockService
-
mockMethodDescriptor
private org.apache.hbase.thirdparty.com.google.protobuf.Descriptors.MethodDescriptor mockMethodDescriptor
-
-
Constructor Details
-
TestServerCall
public TestServerCall()
-
-
Method Details
-
setUp
- Throws:
Exception
-
testSetResponseWithIOException
Test that when IOException occurs during response creation in setResponse, an error response is created and sent to the client instead of leaving the response as null.- Throws:
Exception
-
testSetResponseWithDoubleIOException
Test the case where both normal response creation and error response creation fail with IOException.- Throws:
Exception
-
testSetResponseNormalFlow
Test normal response creation to ensure our changes don't break the normal flow.- Throws:
Exception
-