public static class ClusterEnvironment.Builder extends CoreEnvironment.Builder<ClusterEnvironment.Builder>
Modifier and Type | Method and Description |
---|---|
ClusterEnvironment |
build()
Turns this builder into a real
ClusterEnvironment . |
ClusterEnvironment.Builder |
cryptoManager(CryptoManager cryptoManager)
Sets the cryptography manager for Field-Level Encryption
(reading and writing encrypted document fields).
|
ClusterEnvironment.Builder |
jsonSerializer(JsonSerializer jsonSerializer)
Sets the default serializer for converting between JSON and Java objects.
|
ClusterEnvironment.Builder |
load(ClusterPropertyLoader loader)
Immediately loads the properties from the given loader into the environment.
|
ClusterEnvironment.Builder |
transcoder(Transcoder transcoder)
Allows to override the default transcoder going to be used for all KV operations.
|
compressionConfig, compressionConfig, eventBus, ioConfig, ioConfig, ioEnvironment, load, loggerConfig, loggerConfig, maxNumRequestsInRetry, orphanReporterConfig, orphanReporterConfig, requestTracer, retryStrategy, scheduler, securityConfig, securityConfig, self, thresholdRequestTracerConfig, thresholdRequestTracerConfig, timeoutConfig, timeoutConfig
public ClusterEnvironment.Builder load(ClusterPropertyLoader loader)
loader
- the loader to load the properties from.ClusterEnvironment.Builder
for chaining purposes.public ClusterEnvironment.Builder jsonSerializer(JsonSerializer jsonSerializer)
Providing your own serializer gives you complete control over the conversion.
If this method is not called, the client's behavior depends on whether Jackson is in
the class path. If Jackson is present, an instance of JacksonJsonSerializer
will be used. Otherwise the client will fall back to DefaultJsonSerializer
.
jsonSerializer
- the serializer used for all JSON values.ClusterEnvironment.Builder
for chaining purposes.JacksonJsonSerializer
public ClusterEnvironment.Builder transcoder(Transcoder transcoder)
transcoder
- the transcoder that should be used by default.ClusterEnvironment.Builder
for chaining purposes.public ClusterEnvironment.Builder cryptoManager(CryptoManager cryptoManager)
Note: Use of the Field-Level Encryption functionality is subject to the Couchbase Inc. Enterprise Subscription License Agreement v7
cryptoManager
- (nullable) the manager to use, or null to disable encryption support.public ClusterEnvironment build()
ClusterEnvironment
.build
in class CoreEnvironment.Builder<ClusterEnvironment.Builder>
Copyright © 2020 Couchbase, Inc.. All rights reserved.