public static final class TestServiceGrpc.TestServiceStub extends io.grpc.stub.AbstractAsyncStub<TestServiceGrpc.TestServiceStub>
A simple service to test the various types of RPCs and experiment with performance with various types of payload.
| Modifier and Type | Method and Description |
|---|---|
protected TestServiceGrpc.TestServiceStub |
build(io.grpc.Channel channel,
io.grpc.CallOptions callOptions) |
void |
cacheableUnaryCall(Messages.SimpleRequest request,
io.grpc.stub.StreamObserver<Messages.SimpleResponse> responseObserver)
One request followed by one response.
|
void |
emptyCall(EmptyProtos.Empty request,
io.grpc.stub.StreamObserver<EmptyProtos.Empty> responseObserver)
One empty request followed by one empty response.
|
io.grpc.stub.StreamObserver<Messages.StreamingOutputCallRequest> |
fullDuplexCall(io.grpc.stub.StreamObserver<Messages.StreamingOutputCallResponse> responseObserver)
A sequence of requests with each request served by the server immediately.
|
io.grpc.stub.StreamObserver<Messages.StreamingOutputCallRequest> |
halfDuplexCall(io.grpc.stub.StreamObserver<Messages.StreamingOutputCallResponse> responseObserver)
A sequence of requests followed by a sequence of responses.
|
io.grpc.stub.StreamObserver<Messages.StreamingInputCallRequest> |
streamingInputCall(io.grpc.stub.StreamObserver<Messages.StreamingInputCallResponse> responseObserver)
A sequence of requests followed by one response (streamed upload).
|
void |
streamingOutputCall(Messages.StreamingOutputCallRequest request,
io.grpc.stub.StreamObserver<Messages.StreamingOutputCallResponse> responseObserver)
One request followed by a sequence of responses (streamed download).
|
void |
unaryCall(Messages.SimpleRequest request,
io.grpc.stub.StreamObserver<Messages.SimpleResponse> responseObserver)
One request followed by one response.
|
void |
unimplementedCall(EmptyProtos.Empty request,
io.grpc.stub.StreamObserver<EmptyProtos.Empty> responseObserver)
The test server will not implement this method.
|
protected TestServiceGrpc.TestServiceStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions)
build in class io.grpc.stub.AbstractStub<TestServiceGrpc.TestServiceStub>public void emptyCall(EmptyProtos.Empty request, io.grpc.stub.StreamObserver<EmptyProtos.Empty> responseObserver)
One empty request followed by one empty response.
public void unaryCall(Messages.SimpleRequest request, io.grpc.stub.StreamObserver<Messages.SimpleResponse> responseObserver)
One request followed by one response.
public void cacheableUnaryCall(Messages.SimpleRequest request, io.grpc.stub.StreamObserver<Messages.SimpleResponse> responseObserver)
One request followed by one response. Response has cache control headers set such that a caching HTTP proxy (such as GFE) can satisfy subsequent requests.
public void streamingOutputCall(Messages.StreamingOutputCallRequest request, io.grpc.stub.StreamObserver<Messages.StreamingOutputCallResponse> responseObserver)
One request followed by a sequence of responses (streamed download). The server returns the payload with client desired type and sizes.
public io.grpc.stub.StreamObserver<Messages.StreamingInputCallRequest> streamingInputCall(io.grpc.stub.StreamObserver<Messages.StreamingInputCallResponse> responseObserver)
A sequence of requests followed by one response (streamed upload). The server returns the aggregated size of client payload as the result.
public io.grpc.stub.StreamObserver<Messages.StreamingOutputCallRequest> fullDuplexCall(io.grpc.stub.StreamObserver<Messages.StreamingOutputCallResponse> responseObserver)
A sequence of requests with each request served by the server immediately. As one request could lead to multiple responses, this interface demonstrates the idea of full duplexing.
public io.grpc.stub.StreamObserver<Messages.StreamingOutputCallRequest> halfDuplexCall(io.grpc.stub.StreamObserver<Messages.StreamingOutputCallResponse> responseObserver)
A sequence of requests followed by a sequence of responses. The server buffers all the client requests and then serves them in order. A stream of responses are returned to the client when the server starts with first request.
public void unimplementedCall(EmptyProtos.Empty request, io.grpc.stub.StreamObserver<EmptyProtos.Empty> responseObserver)
The test server will not implement this method. It will be used to test the behavior when clients call unimplemented methods.