Class GrpcServerCdiExtension.ServerProducer
java.lang.Object
io.helidon.microprofile.grpc.server.GrpcServerCdiExtension.ServerProducer
- Enclosing class:
- GrpcServerCdiExtension
A CDI producer that can supply the running
GrpcServer
an in-process Channel.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionio.grpc.Channelchannel()Produces an in-processChannelto connect to the running gRPC server.io.grpc.inprocess.InProcessChannelBuilderProduces an in-processInProcessChannelBuilderto connect to the running gRPC server.server()Produce theGrpcServer.supply()Produce aSupplierthat can supply theGrpcServer.
-
Constructor Details
-
ServerProducer
public ServerProducer()
-
-
Method Details
-
server
Produce theGrpcServer.- Returns:
- the
GrpcServer
-
supply
Produce aSupplierthat can supply theGrpcServer.This could be useful where an injection point has the server injected before the
GrpcServerCdiExtension.startServer(java.lang.Object, jakarta.enterprise.inject.spi.BeanManager)method has actually started it. In that case aSupplier<GrpcServer>can be injected instead that will be able to lazily supply the server.- Returns:
- a
Supplierthat can supply theGrpcServer
-
channel
Produces an in-processChannelto connect to the running gRPC server.- Returns:
- an in-process
Channelto connect to the running gRPC server
-
channelBuilder
Produces an in-processInProcessChannelBuilderto connect to the running gRPC server.- Returns:
- an in-process
InProcessChannelBuilderto connect to the running gRPC server
-