java.lang.Object
io.helidon.grpc.server.GrpcServerConfiguration.Builder
- All Implemented Interfaces:
Builder<GrpcServerConfiguration.Builder,,GrpcServerConfiguration> Supplier<GrpcServerConfiguration>
- Enclosing interface:
- GrpcServerConfiguration
public static final class GrpcServerConfiguration.Builder
extends Object
implements Builder<GrpcServerConfiguration.Builder,GrpcServerConfiguration>
A
GrpcServerConfiguration builder.-
Method Summary
Modifier and TypeMethodDescriptionbuild()Build the instance from this builder.Update the builder from configuration.context()Current HelidonContext.Configure the application scoped context to be used as a parent for webserver request contexts.Set the name of the gRPC server.port(int port) Sets server port.tlsConfig(GrpcTlsDescriptor tlsConfig) Configures TLS configuration to use with the server socket.Sets an opentracing.io tracer.Sets an opentracing.io tracer.tracingConfig(GrpcTracingConfig tracingConfig) Set trace configuration.workersCount(int workers) Sets a count of threads in pool used to process HTTP requests.
-
Method Details
-
config
Update the builder from configuration.- Parameters:
config- configuration instance- Returns:
- updated builder
-
name
Set the name of the gRPC server.Configuration key:
name- Parameters:
name- the name of the gRPC server- Returns:
- an updated builder
-
port
Sets server port. If port is0or less then any available ephemeral port will be used.Configuration key:
port- Parameters:
port- the server port- Returns:
- an updated builder
-
context
Configure the application scoped context to be used as a parent for webserver request contexts.- Parameters:
context- top level context- Returns:
- an updated builder
-
tracer
Sets an opentracing.io tracer. (Default isGlobalTracer.)- Parameters:
tracer- a tracer to set- Returns:
- an updated builder
-
tracer
Sets an opentracing.io tracer. (Default isGlobalTracer.)- Parameters:
tracerBuilder- a tracer builder to set; will be built as a first step of this method execution- Returns:
- updated builder
-
tracingConfig
Set trace configuration.- Parameters:
tracingConfig- the tracing configuration to set- Returns:
- an updated builder
-
workersCount
Sets a count of threads in pool used to process HTTP requests. Default value isCPU_COUNT * 2.Configuration key:
workers- Parameters:
workers- a workers count- Returns:
- an updated builder
-
tlsConfig
Configures TLS configuration to use with the server socket. If notnullthen the server enforces an TLS communication.- Parameters:
tlsConfig- a TLS configuration to use- Returns:
- this builder
-
context
Current HelidonContext.- Returns:
- current context
-
build
Description copied from interface:BuilderBuild the instance from this builder.- Specified by:
buildin interfaceBuilder<GrpcServerConfiguration.Builder,GrpcServerConfiguration> - Returns:
- instance of the built type
-