Client - gRPC service that any client built from this
factory represents.BlockingClient - Blocking gRPC service that any client
built from this builder represents.public abstract class GrpcClientFactory<Client extends GrpcClient<BlockingClient>,BlockingClient extends BlockingGrpcClient<Client>>
extends Object
Client
contract.| Constructor and Description |
|---|
GrpcClientFactory() |
| Modifier and Type | Method and Description |
|---|---|
protected BufferDecoderGroup |
bufferDecoderGroup()
Get the supported
BufferDecoderGroup for this client factory. |
GrpcClientFactory<Client,BlockingClient> |
bufferDecoderGroup(BufferDecoderGroup bufferDecoderGroup)
Sets the supported
BufferDecoderGroup for this client factory. |
protected abstract BlockingClient |
newBlockingClient(GrpcClientCallFactory clientCallFactory)
Create a new client that follows the specified gRPC
BlockingClient contract using the passed GrpcClientCallFactory. |
BlockingClient |
newBlockingClientForCallFactory(GrpcClientCallFactory clientCallFactory)
Create a new client that follows the specified gRPC
BlockingClient contract using the passed GrpcClientCallFactory. |
protected abstract Client |
newClient(GrpcClientCallFactory clientCallFactory)
Create a new client that follows the specified gRPC
Client contract using the passed GrpcClientCallFactory. |
Client |
newClientForCallFactory(GrpcClientCallFactory clientCallFactory)
Create a new client that follows the specified gRPC
Client contract using the passed GrpcClientCallFactory. |
protected List<ContentCodec> |
supportedMessageCodings()
Deprecated.
Use generated code methods targeting
List of
BufferEncoders and BufferDecoderGroup. |
GrpcClientFactory<Client,BlockingClient> |
supportedMessageCodings(List<ContentCodec> codings)
Deprecated.
Use generated code methods targeting
List of
BufferEncoders and BufferDecoderGroup. |
public final Client newClientForCallFactory(GrpcClientCallFactory clientCallFactory)
Client contract using the passed GrpcClientCallFactory.clientCallFactory - GrpcClientCallFactory to use for creating client calls.
The returned Client should own the lifecycle of this factory.Client contract.public final BlockingClient newBlockingClientForCallFactory(GrpcClientCallFactory clientCallFactory)
BlockingClient contract using the passed GrpcClientCallFactory.clientCallFactory - GrpcClientCallFactory to use for creating client calls.
The returned Client should own the lifecycle of this factory.BlockingClient contract.@Deprecated public GrpcClientFactory<Client,BlockingClient> supportedMessageCodings(List<ContentCodec> codings)
List of
BufferEncoders and BufferDecoderGroup.Identity.identity() is supportedcodings - The supported encodings ContentCodecs for this client.this@Deprecated protected List<ContentCodec> supportedMessageCodings()
List of
BufferEncoders and BufferDecoderGroup.ContentCodecs for this client factory.ContentCodecs for this client factory.public GrpcClientFactory<Client,BlockingClient> bufferDecoderGroup(BufferDecoderGroup bufferDecoderGroup)
BufferDecoderGroup for this client factory.
By default only Identity.identityEncoder() is supported
BufferDecoderGroup.bufferDecoderGroup - The supported BufferDecoderGroup for this client.thisprotected BufferDecoderGroup bufferDecoderGroup()
BufferDecoderGroup for this client factory.BufferDecoderGroup for this client factory.protected abstract Client newClient(GrpcClientCallFactory clientCallFactory)
Client contract using the passed GrpcClientCallFactory.clientCallFactory - GrpcClientCallFactory to use for creating client calls.
The returned Client should own the lifecycle of this factory.Client contract.protected abstract BlockingClient newBlockingClient(GrpcClientCallFactory clientCallFactory)
BlockingClient contract using the passed GrpcClientCallFactory.clientCallFactory - GrpcClientCallFactory to use for creating client calls.
The returned Client should own the lifecycle of this factory.BlockingClient contract.