Interface GrpcServerFactory

All Known Implementing Classes:
DefaultGrpcServerFactory, InProcessGrpcServerFactory, NettyGrpcServerFactory, ShadedNettyGrpcServerFactory

public interface GrpcServerFactory
Factory interface that can be used to create a gRPC Server.
Author:
David Syer, Chris Bono
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addService(io.grpc.ServerServiceDefinition service)
    Adds a service definition to the server.
    io.grpc.Server
    Gets a new fully configured but not started Server instance.
    default boolean
    supports(io.grpc.ServerInterceptor interceptor, io.grpc.ServerServiceDefinition service)
     
  • Method Details

    • createServer

      io.grpc.Server createServer()
      Gets a new fully configured but not started Server instance. Clients should not be able to connect to the returned server until Server.start() is called (which happens when the GrpcServerLifecycle is started).
      Returns:
      a fully configured not started Server or null if the server has no lifecycle
      See Also:
    • addService

      void addService(io.grpc.ServerServiceDefinition service)
      Adds a service definition to the server. Must be called prior to Server.start().
      Parameters:
      service - the service definition to add
    • supports

      default boolean supports(io.grpc.ServerInterceptor interceptor, io.grpc.ServerServiceDefinition service)