Class PutClusterSettingsRequest
- All Implemented Interfaces:
JsonpSerializable
Configure and update dynamic settings on a running cluster. You can also
configure dynamic settings locally on an unstarted or shut down node in
elasticsearch.yml.
Updates made with this API can be persistent, which apply across cluster restarts, or transient, which reset after a cluster restart. You can also reset transient or persistent settings by assigning them a null value.
If you configure the same setting using multiple methods, Elasticsearch
applies the settings in following order of precedence: 1) Transient setting;
2) Persistent setting; 3) elasticsearch.yml setting; 4) Default
setting value. For example, you can apply a transient setting to override a
persistent setting or elasticsearch.yml setting. However, a
change to an elasticsearch.yml setting will not override a
defined transient or persistent setting.
TIP: In Elastic Cloud, use the user settings feature to configure all cluster
settings. This method automatically rejects unsafe settings that could break
your cluster. If you run Elasticsearch on your own hardware, use this API to
configure dynamic cluster settings. Only use elasticsearch.yml
for static cluster settings and node settings. The API doesn’t require a
restart and ensures a setting’s value is the same on all nodes.
WARNING: Transient cluster settings are no longer recommended. Use persistent cluster settings instead. If a cluster becomes unstable, transient settings can clear unexpectedly, resulting in a potentially undesired cluster configuration.
- See Also:
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class co.elastic.clients.elasticsearch._types.RequestBase
RequestBase.AbstractBuilder<BuilderT extends RequestBase.AbstractBuilder<BuilderT>> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final JsonpDeserializer<PutClusterSettingsRequest>Json deserializer forPutClusterSettingsRequestEndpoint "cluster.put_settings". -
Method Summary
Modifier and TypeMethodDescriptionfinal BooleanReturn settings in flat format (default: false)final TimeExplicit operation timeout for connection to master nodestatic PutClusterSettingsRequestThe settings that persist after the cluster restarts.voidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) Serialize this object to JSON.protected voidserializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) protected static voidsetupPutClusterSettingsRequestDeserializer(ObjectDeserializer<PutClusterSettingsRequest.Builder> op) final Timetimeout()Explicit operation timeoutThe settings that do not persist after the cluster restarts.Methods inherited from class co.elastic.clients.elasticsearch._types.RequestBase
toString
-
Field Details
-
_DESERIALIZER
Json deserializer forPutClusterSettingsRequest -
_ENDPOINT
public static final Endpoint<PutClusterSettingsRequest,PutClusterSettingsResponse, _ENDPOINTErrorResponse> Endpoint "cluster.put_settings".
-
-
Method Details
-
of
public static PutClusterSettingsRequest of(Function<PutClusterSettingsRequest.Builder, ObjectBuilder<PutClusterSettingsRequest>> fn) -
flatSettings
Return settings in flat format (default: false)API name:
flat_settings -
masterTimeout
Explicit operation timeout for connection to master nodeAPI name:
master_timeout -
persistent
The settings that persist after the cluster restarts.API name:
persistent -
timeout
Explicit operation timeoutAPI name:
timeout -
transient_
The settings that do not persist after the cluster restarts.API name:
transient -
serialize
Serialize this object to JSON.- Specified by:
serializein interfaceJsonpSerializable
-
serializeInternal
-
setupPutClusterSettingsRequestDeserializer
protected static void setupPutClusterSettingsRequestDeserializer(ObjectDeserializer<PutClusterSettingsRequest.Builder> op)
-