java.lang.Object
io.helidon.grpc.server.GrpcServerBasicConfig
- All Implemented Interfaces:
GrpcServerConfiguration
Configuration class for the
GrpcServer implementations.-
Nested Class Summary
Nested classes/interfaces inherited from interface io.helidon.grpc.server.GrpcServerConfiguration
GrpcServerConfiguration.Builder -
Field Summary
Fields inherited from interface io.helidon.grpc.server.GrpcServerConfiguration
DEFAULT_NAME, DEFAULT_PORT, DEFAULT_WORKER_COUNT -
Method Summary
Modifier and TypeMethodDescriptioncontext()The top levelContextto be used by the server.intReturns the maximum allowed number of rapid resets (stream RST sent by client before any data have been sent by server).name()Get the server name.intport()Get the server port.Returns the period for counting rapid resets (stream RST sent by client before any data have been sent by server).Returns a SslConfiguration to use with the server socket.tracer()Returns aTracer.Returns tracing configuration.booleanDetermine whether use native transport if possible.intworkers()Returns a count of threads in s pool used to process gRPC requests.
-
Method Details
-
name
Get the server name.- Specified by:
namein interfaceGrpcServerConfiguration- Returns:
- the server name
-
port
public int port()Get the server port.- Specified by:
portin interfaceGrpcServerConfiguration- Returns:
- the server port
-
context
Description copied from interface:GrpcServerConfigurationThe top levelContextto be used by the server.- Specified by:
contextin interfaceGrpcServerConfiguration- Returns:
- a context instance with registered application scoped instances
-
useNativeTransport
public boolean useNativeTransport()Determine whether use native transport if possible.If native transport support is enabled, gRPC server will use epoll on Linux, or kqueue on OS X. Otherwise, the standard NIO transport will be used.
- Specified by:
useNativeTransportin interfaceGrpcServerConfiguration- Returns:
trueif native transport should be used
-
tracer
Description copied from interface:GrpcServerConfigurationReturns aTracer. Default isTracer.global().- Specified by:
tracerin interfaceGrpcServerConfiguration- Returns:
- a tracer to use - never
null
-
tracingConfig
Description copied from interface:GrpcServerConfigurationReturns tracing configuration.- Specified by:
tracingConfigin interfaceGrpcServerConfiguration- Returns:
- a tracing configuration.
-
workers
public int workers()Description copied from interface:GrpcServerConfigurationReturns a count of threads in s pool used to process gRPC requests.Default value is
CPU_COUNT * 2.- Specified by:
workersin interfaceGrpcServerConfiguration- Returns:
- a workers count
-
tlsConfig
Description copied from interface:GrpcServerConfigurationReturns a SslConfiguration to use with the server socket. If notnullthen the server enforces an SSL communication.- Specified by:
tlsConfigin interfaceGrpcServerConfiguration- Returns:
- a TLS configuration to use
-
rapidResetCheckPeriod
Description copied from interface:GrpcServerConfigurationReturns the period for counting rapid resets (stream RST sent by client before any data have been sent by server).- Specified by:
rapidResetCheckPeriodin interfaceGrpcServerConfiguration- Returns:
- the period for counting rapid resets
-
maxRapidResets
public int maxRapidResets()Description copied from interface:GrpcServerConfigurationReturns the maximum allowed number of rapid resets (stream RST sent by client before any data have been sent by server). When reached withinGrpcServerConfiguration.rapidResetCheckPeriod(), GOAWAY is sent to client and connection is closed.- Specified by:
maxRapidResetsin interfaceGrpcServerConfiguration- Returns:
- the maximum allowed number of rapid resets
-