public interface GrpcChannelFactory
extends java.lang.AutoCloseable
Channels for a given service name. Implementations are encouraged to utilize
connection pooling and thus close should be called before disposing it.| Modifier and Type | Method and Description |
|---|---|
io.grpc.Channel |
createChannel(java.lang.String name)
Creates a new channel for the given service name.
|
io.grpc.Channel |
createChannel(java.lang.String name,
java.util.List<io.grpc.ClientInterceptor> interceptors)
Creates a new channel for the given service name.
|
io.grpc.Channel createChannel(java.lang.String name)
ClientInterceptors.
Note: The underlying implementation might reuse existing ManagedChannels allow connection reuse.
name - The name of the service.io.grpc.Channel createChannel(java.lang.String name,
java.util.List<io.grpc.ClientInterceptor> interceptors)
ClientInterceptors.
Note: The underlying implementation might reuse existing ManagedChannels allow connection reuse.
Note: The given interceptors will be applied after the global interceptors. But the interceptors that were applied last, will be called first.
name - The name of the service.interceptors - A list of additional client interceptors that should be added to the channel.