public abstract class ServerFactory
extends java.lang.Object
gRPC server
factory.Modifier and Type | Class and Description |
---|---|
static class |
ServerFactory.InetSocketAddressServerFactory
Creates a
gRPC Server using the default server factory. |
static interface |
ServerFactory.UrlFactory
Factory that constructs client-accessible URLs from a local server address and port.
|
Constructor and Description |
---|
ServerFactory() |
Modifier and Type | Method and Description |
---|---|
abstract org.apache.beam.vendor.grpc.v1p48p1.io.grpc.Server |
allocateAddressAndCreate(java.util.List<org.apache.beam.vendor.grpc.v1p48p1.io.grpc.BindableService> services,
org.apache.beam.model.pipeline.v1.Endpoints.ApiServiceDescriptor.Builder builder)
Creates an instance of this server using an ephemeral address.
|
abstract org.apache.beam.vendor.grpc.v1p48p1.io.grpc.Server |
create(java.util.List<org.apache.beam.vendor.grpc.v1p48p1.io.grpc.BindableService> services,
org.apache.beam.model.pipeline.v1.Endpoints.ApiServiceDescriptor serviceDescriptor)
Creates an instance of this server at the address specified by the given service descriptor and
bound to multiple services.
|
static ServerFactory |
createDefault()
Create a default
ServerFactory.InetSocketAddressServerFactory . |
static ServerFactory |
createEpollDomainSocket()
Create a
EpollDomainSocket . |
static ServerFactory |
createEpollSocket()
Create a
EpollSocket . |
static ServerFactory |
createWithPortSupplier(java.util.function.Supplier<java.lang.Integer> portSupplier)
Create a
ServerFactory.InetSocketAddressServerFactory that uses ports from a supplier. |
static ServerFactory |
createWithUrlFactory(ServerFactory.UrlFactory urlFactory)
Create a
ServerFactory.InetSocketAddressServerFactory that uses the given url factory. |
static ServerFactory |
createWithUrlFactoryAndPortSupplier(ServerFactory.UrlFactory urlFactory,
java.util.function.Supplier<java.lang.Integer> portSupplier)
Create a
ServerFactory.InetSocketAddressServerFactory that uses the given url factory and ports from
a supplier. |
public static ServerFactory createDefault()
ServerFactory.InetSocketAddressServerFactory
.public static ServerFactory createWithUrlFactory(ServerFactory.UrlFactory urlFactory)
ServerFactory.InetSocketAddressServerFactory
that uses the given url factory.public static ServerFactory createWithPortSupplier(java.util.function.Supplier<java.lang.Integer> portSupplier)
ServerFactory.InetSocketAddressServerFactory
that uses ports from a supplier.public static ServerFactory createWithUrlFactoryAndPortSupplier(ServerFactory.UrlFactory urlFactory, java.util.function.Supplier<java.lang.Integer> portSupplier)
ServerFactory.InetSocketAddressServerFactory
that uses the given url factory and ports from
a supplier.public static ServerFactory createEpollSocket()
EpollSocket
.public static ServerFactory createEpollDomainSocket()
EpollDomainSocket
.public abstract org.apache.beam.vendor.grpc.v1p48p1.io.grpc.Server allocateAddressAndCreate(java.util.List<org.apache.beam.vendor.grpc.v1p48p1.io.grpc.BindableService> services, org.apache.beam.model.pipeline.v1.Endpoints.ApiServiceDescriptor.Builder builder) throws java.io.IOException
Endpoints.ApiServiceDescriptor.Builder
. Server applies GrpcContextHeaderAccessorProvider.interceptor()
to all incoming requests.java.io.IOException
public abstract org.apache.beam.vendor.grpc.v1p48p1.io.grpc.Server create(java.util.List<org.apache.beam.vendor.grpc.v1p48p1.io.grpc.BindableService> services, org.apache.beam.model.pipeline.v1.Endpoints.ApiServiceDescriptor serviceDescriptor) throws java.io.IOException
GrpcContextHeaderAccessorProvider.interceptor()
to all incoming requests.java.io.IOException