Class CoreEnvironment
public class CoreEnvironment extends Object
Note that unless you are using the core directly, you want to consider the child implementations for each language binding (i.e. the ClusterEnvironment for the java client).
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCoreEnvironment.Builder<SELF extends CoreEnvironment.Builder<SELF>> -
Field Summary
Fields Modifier and Type Field Description static longDEFAULT_MAX_NUM_REQUESTS_IN_RETRYDefault maximum requests being queued in retry before performing backpressure cancellations. -
Constructor Summary
Constructors Modifier Constructor Description protectedCoreEnvironment(CoreEnvironment.Builder builder) -
Method Summary
Modifier and Type Method Description static CoreEnvironment.Builderbuilder()Optional<String>clientHash()If present, returns the git hash for the client at build time.Optional<String>clientVersion()If present, returns the client version at build time.CompressionConfigcompressionConfig()Returns the current compression configuration.Optional<String>coreHash()If present, returns the git hash for the core at build time.Optional<String>coreVersion()If present, returns the core version at build time.static CoreEnvironmentcreate()protected StringdefaultAgentTitle()Returns the default user agent name that is used as part of the resulting string.EventBuseventBus()The central event bus which manages all kinds of messages flowing throughout the client.StringexportAsString(Context.ExportFormat format)Export this environment into the specified format.IoConfigioConfig()Returns the current configuration for all I/O-related settings.IoEnvironmentioEnvironment()Holds the environmental configuration/state that is tied to the IO layer.LoggerConfigloggerConfig()Returns the current logger configuration.Metermeter()OrphanReporterorphanReporter()Returns the orphan reporter on this environment.RequestTracerrequestTracer()Returns the request tracer for response time observability.RetryStrategyretryStrategy()Returns the retry strategy on this environment.Schedulerscheduler()Returns the scheduler used to schedule reactive, async tasks across the SDK.SecurityConfigsecurityConfig()Returns the current security configuration (TLS etc.).voidshutdown()Shuts down this Environment with the default disconnect timeout.voidshutdown(Duration timeout)Shuts down this Environment with a custom timeout.CompletableFuture<Void>shutdownAsync()Shuts down this Environment with the default disconnect timeout.CompletableFuture<Void>shutdownAsync(Duration timeout)Shuts down this Environment with a custom timeout.Mono<Void>shutdownReactive()Shuts down this Environment with the default disconnect timeout.Mono<Void>shutdownReactive(Duration timeout)Shuts down this Environment with a custom timeout.TimeoutConfigtimeoutConfig()Returns the configuration for all default timeouts.Timertimer()Returns the timer used to schedule timeouts and retries amongst other tasks.StringtoString()UserAgentuserAgent()User agent used to identify this client against the server.
-
Field Details
-
DEFAULT_MAX_NUM_REQUESTS_IN_RETRY
public static final long DEFAULT_MAX_NUM_REQUESTS_IN_RETRYDefault maximum requests being queued in retry before performing backpressure cancellations.- See Also:
- Constant Field Values
-
-
Constructor Details
-
CoreEnvironment
-
-
Method Details
-
create
-
builder
-
defaultAgentTitle
Returns the default user agent name that is used as part of the resulting string. -
clientHash
If present, returns the git hash for the client at build time. -
coreHash
If present, returns the git hash for the core at build time. -
clientVersion
If present, returns the client version at build time. -
coreVersion
If present, returns the core version at build time. -
userAgent
User agent used to identify this client against the server. -
eventBus
The central event bus which manages all kinds of messages flowing throughout the client.- Returns:
- the event bus currently in use.
-
ioEnvironment
Holds the environmental configuration/state that is tied to the IO layer. -
ioConfig
Returns the current configuration for all I/O-related settings. -
timeoutConfig
Returns the configuration for all default timeouts. -
securityConfig
Returns the current security configuration (TLS etc.). -
compressionConfig
Returns the current compression configuration. -
loggerConfig
Returns the current logger configuration. -
scheduler
Returns the scheduler used to schedule reactive, async tasks across the SDK. -
requestTracer
Returns the request tracer for response time observability.Note that this right now is unsupported, volatile API and subject to change!
-
meter
-
timer
Returns the timer used to schedule timeouts and retries amongst other tasks. -
retryStrategy
Returns the retry strategy on this environment. -
orphanReporter
Returns the orphan reporter on this environment. -
shutdownAsync
Shuts down this Environment with the default disconnect timeout.Note that once shutdown, the environment cannot be restarted so it is advised to perform this operation at the very last operation in the SDK shutdown process.
-
shutdownAsync
Shuts down this Environment with a custom timeout.Note that once shutdown, the environment cannot be restarted so it is advised to perform this operation at the very last operation in the SDK shutdown process.
- Parameters:
timeout- the timeout to wait maximum.
-
shutdownReactive
Shuts down this Environment with the default disconnect timeout.Note that once shutdown, the environment cannot be restarted so it is advised to perform this operation at the very last operation in the SDK shutdown process.
-
shutdownReactive
Shuts down this Environment with a custom timeout.Note that once shutdown, the environment cannot be restarted so it is advised to perform this operation at the very last operation in the SDK shutdown process.
- Parameters:
timeout- the timeout to wait maximum.
-
shutdown
Shuts down this Environment with a custom timeout.Note that once shutdown, the environment cannot be restarted so it is advised to perform this operation at the very last operation in the SDK shutdown process.
- Parameters:
timeout- the timeout to wait maximum.
-
shutdown
public void shutdown()Shuts down this Environment with the default disconnect timeout.Note that once shutdown, the environment cannot be restarted so it is advised to perform this operation at the very last operation in the SDK shutdown process.
-
exportAsString
Export this environment into the specified format.- Parameters:
format- the format to export into.- Returns:
- the exported format as a string representation.
-
toString
-