Class CreateSnapshotRequest
- java.lang.Object
-
- org.opensearch.client.opensearch._types.RequestBase
-
- org.opensearch.client.opensearch.snapshot.CreateSnapshotRequest
-
- All Implemented Interfaces:
JsonpSerializable,PlainJsonSerializable
@JsonpDeserializable @Generated("org.opensearch.client.codegen.CodeGenerator") public class CreateSnapshotRequest extends RequestBase implements PlainJsonSerializable
Creates a snapshot in a repository.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCreateSnapshotRequest.BuilderBuilder forCreateSnapshotRequest.-
Nested classes/interfaces inherited from class org.opensearch.client.opensearch._types.RequestBase
RequestBase.AbstractBuilder<BuilderT extends RequestBase.AbstractBuilder<BuilderT>>
-
-
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<CreateSnapshotRequest>_DESERIALIZERJson deserializer forCreateSnapshotRequeststatic Endpoint<CreateSnapshotRequest,CreateSnapshotResponse,ErrorResponse>_ENDPOINTEndpoint "snapshot.create".
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description TimeclusterManagerTimeout()Operation timeout for connection to cluster-manager node.booleanequals(java.lang.Object o)java.util.List<java.lang.String>featureStates()Feature states to include in the snapshot.inthashCode()java.lang.BooleanignoreUnavailable()Iftrue, the request ignores data streams and indexes inindicesthat are missing or closed.java.lang.BooleanincludeGlobalState()Iftrue, the current cluster state is included in the snapshot.java.util.List<java.lang.String>indices()API name:indicesTimemasterTimeout()Deprecated.java.util.Map<java.lang.String,JsonData>metadata()API name:metadatastatic CreateSnapshotRequestof(java.util.function.Function<CreateSnapshotRequest.Builder,ObjectBuilder<CreateSnapshotRequest>> fn)java.lang.Booleanpartial()Iftrue, allows restoring a partial snapshot of indexes with unavailable shards.java.lang.Stringrepository()Required - Repository for the snapshot.voidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)Serialize this object to JSON.protected voidserializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)protected static voidsetupCreateSnapshotRequestDeserializer(ObjectDeserializer<CreateSnapshotRequest.Builder> op)java.lang.Stringsnapshot()Required - Name of the snapshot.java.lang.BooleanwaitForCompletion()Iftrue, the request returns a response when the snapshot is complete.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.opensearch.client.json.PlainJsonSerializable
toJsonString
-
-
-
-
Field Detail
-
_DESERIALIZER
public static final JsonpDeserializer<CreateSnapshotRequest> _DESERIALIZER
Json deserializer forCreateSnapshotRequest
-
_ENDPOINT
public static final Endpoint<CreateSnapshotRequest,CreateSnapshotResponse,ErrorResponse> _ENDPOINT
Endpoint "snapshot.create".
-
-
Method Detail
-
of
public static CreateSnapshotRequest of(java.util.function.Function<CreateSnapshotRequest.Builder,ObjectBuilder<CreateSnapshotRequest>> fn)
-
clusterManagerTimeout
@Nullable public final Time clusterManagerTimeout()
Operation timeout for connection to cluster-manager node.API name:
cluster_manager_timeout
-
featureStates
@Nonnull public final java.util.List<java.lang.String> featureStates()
Feature states to include in the snapshot. Each feature state includes one or more system indexes containing related data. You can view a list of eligible features using the get features API. Ifinclude_global_stateistrue, all current feature states are included by default. Ifinclude_global_stateisfalse, no feature states are included by default.API name:
feature_states
-
ignoreUnavailable
@Nullable public final java.lang.Boolean ignoreUnavailable()
Iftrue, the request ignores data streams and indexes inindicesthat are missing or closed. Iffalse, the request returns an error for any data stream or index that is missing or closed.API name:
ignore_unavailable
-
includeGlobalState
@Nullable public final java.lang.Boolean includeGlobalState()
Iftrue, the current cluster state is included in the snapshot. The cluster state includes persistent cluster settings, composable index templates, legacy index templates, ingest pipelines, and ILM policies. It also includes data stored in system indexes, such as Watches and task records (configurable withfeature_states).API name:
include_global_state
-
indices
@Nonnull public final java.util.List<java.lang.String> indices()
API name:indices
-
masterTimeout
@Deprecated @Nullable public final Time masterTimeout()
Deprecated.Period to wait for a connection to the cluster-manager node. If no response is received before the timeout expires, the request fails and returns an error.API name:
master_timeout
-
metadata
@Nonnull public final java.util.Map<java.lang.String,JsonData> metadata()
API name:metadata
-
partial
@Nullable public final java.lang.Boolean partial()
Iftrue, allows restoring a partial snapshot of indexes with unavailable shards. Only shards that were successfully included in the snapshot will be restored. All missing shards will be recreated as empty. Iffalse, the entire restore operation will fail if one or more indexes included in the snapshot do not have all primary shards available.API name:
partial
-
repository
@Nonnull public final java.lang.String repository()
Required - Repository for the snapshot.API name:
repository
-
snapshot
@Nonnull public final java.lang.String snapshot()
Required - Name of the snapshot. Must be unique in the repository.API name:
snapshot
-
waitForCompletion
@Nullable public final java.lang.Boolean waitForCompletion()
Iftrue, the request returns a response when the snapshot is complete. Iffalse, the request returns a response when the snapshot initializes.API name:
wait_for_completion
-
serialize
public void serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)Serialize this object to JSON.- Specified by:
serializein interfaceJsonpSerializable
-
serializeInternal
protected void serializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
-
setupCreateSnapshotRequestDeserializer
protected static void setupCreateSnapshotRequestDeserializer(ObjectDeserializer<CreateSnapshotRequest.Builder> op)
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
-