Class RestoreRequest
- All Implemented Interfaces:
JsonpSerializable
You can restore a snapshot only to a running cluster with an elected master node. The snapshot repository must be registered and available to the cluster. The snapshot and cluster versions must be compatible.
To restore a snapshot, the cluster's global metadata must be writable. Ensure there are't any cluster blocks that prevent writes. The restore operation ignores index blocks.
Before you restore a data stream, ensure the cluster contains a matching index template with data streams enabled. To check, use the index management feature in Kibana or the get index template API:
GET _index_template/*?filter_path=index_templates.name,index_templates.index_template.index_patterns,index_templates.index_template.data_stream
If no such template exists, you can create one or restore a cluster state that contains one. Without a matching index template, a data stream can't roll over or create backing indices.
If your snapshot contains data from App Search or Workplace Search, you must restore the Enterprise Search encryption key before you restore the snapshot.
- 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<RestoreRequest>Json deserializer forRestoreRequeststatic final Endpoint<RestoreRequest,RestoreResponse, ErrorResponse> Endpoint "snapshot.restore". -
Method Summary
Modifier and TypeMethodDescriptionAPI name:feature_statesAPI name:ignore_index_settingsfinal BooleanAPI name:ignore_unavailablefinal BooleanAPI name:include_aliasesfinal BooleanAPI name:include_global_statefinal IndexSettingsAPI name:index_settingsindices()API name:indicesfinal TimeExplicit operation timeout for connection to master nodestatic RestoreRequestfinal Booleanpartial()API name:partialfinal StringAPI name:rename_patternfinal StringAPI name:rename_replacementfinal StringRequired - A repository namevoidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) Serialize this object to JSON.protected voidserializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) protected static voidfinal Stringsnapshot()Required - A snapshot namefinal BooleanShould this request wait until the operation has completed before returningMethods inherited from class co.elastic.clients.elasticsearch._types.RequestBase
toString
-
Field Details
-
_DESERIALIZER
Json deserializer forRestoreRequest -
_ENDPOINT
Endpoint "snapshot.restore".
-
-
Method Details
-
of
-
featureStates
API name:feature_states -
ignoreIndexSettings
API name:ignore_index_settings -
includeAliases
API name:include_aliases -
includeGlobalState
API name:include_global_state -
indexSettings
API name:index_settings -
indices
API name:indices -
masterTimeout
Explicit operation timeout for connection to master nodeAPI name:
master_timeout -
partial
API name:partial -
renamePattern
API name:rename_pattern -
renameReplacement
API name:rename_replacement -
repository
Required - A repository nameAPI name:
repository -
snapshot
Required - A snapshot nameAPI name:
snapshot -
waitForCompletion
Should this request wait until the operation has completed before returningAPI name:
wait_for_completion -
serialize
Serialize this object to JSON.- Specified by:
serializein interfaceJsonpSerializable
-
serializeInternal
-
setupRestoreRequestDeserializer
protected static void setupRestoreRequestDeserializer(ObjectDeserializer<RestoreRequest.Builder> op)
-