Package io.micronaut.grpc.channels
Class GrpcChannelBuilderFactory
java.lang.Object
io.micronaut.grpc.channels.GrpcChannelBuilderFactory
Factory class for creating
NettyChannelBuilder
instances.- Since:
- 1.0
- Author:
- graemerocher
-
Constructor Summary
ConstructorDescriptionGrpcChannelBuilderFactory
(io.micronaut.context.ApplicationContext beanContext, ExecutorService executorService) Default constructor. -
Method Summary
Modifier and TypeMethodDescriptionprotected io.grpc.netty.NettyChannelBuilder
managedChannelBuilder
(String target, List<io.grpc.ClientInterceptor> interceptors) Constructor a managed channel build for the given target name and interceptors.
-
Constructor Details
-
GrpcChannelBuilderFactory
public GrpcChannelBuilderFactory(io.micronaut.context.ApplicationContext beanContext, @Named("io") ExecutorService executorService) Default constructor.- Parameters:
beanContext
- The bean contextexecutorService
- The I/O executor service
-
-
Method Details
-
managedChannelBuilder
@Bean @Prototype protected io.grpc.netty.NettyChannelBuilder managedChannelBuilder(@Parameter String target, List<io.grpc.ClientInterceptor> interceptors) Constructor a managed channel build for the given target name and interceptors.- Parameters:
target
- The target nameinterceptors
- The interceptors- Returns:
- The channel builder
-