Class ReindexRequest.Builder
- All Implemented Interfaces:
WithJson<ReindexRequest.Builder>,ObjectBuilder<ReindexRequest>
- Enclosing class:
- ReindexRequest
ReindexRequest.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aReindexRequest.final ReindexRequest.BuilderIndicates whether to continue reindexing even when there are conflicts.final ReindexRequest.Builderdest(Destination value) Required - The destination you are copying to.final ReindexRequest.BuilderRequired - The destination you are copying to.final ReindexRequest.BuilderThe maximum number of documents to reindex.final ReindexRequest.BuilderIftrue, the request refreshes affected shards to make this operation visible to search.final ReindexRequest.BuilderrequestsPerSecond(Float value) The throttle for this request in sub-requests per second.final ReindexRequest.BuilderrequireAlias(Boolean value) Iftrue, the destination must be an index alias.final ReindexRequest.BuilderThe script to run to update the document source or metadata when reindexing.final ReindexRequest.BuilderThe script to run to update the document source or metadata when reindexing.final ReindexRequest.BuilderThe period of time that a consistent view of the index should be maintained for scrolled search.final ReindexRequest.BuilderThe period of time that a consistent view of the index should be maintained for scrolled search.protected ReindexRequest.Builderself()final ReindexRequest.BuilderThe number of slices this task should be divided into.final ReindexRequest.BuilderThe number of slices this task should be divided into.final ReindexRequest.BuilderRequired - The source you are copying from.final ReindexRequest.BuilderRequired - The source you are copying from.final ReindexRequest.BuilderThe period each indexing waits for automatic index creation, dynamic mapping updates, and waiting for active shards.final ReindexRequest.BuilderThe period each indexing waits for automatic index creation, dynamic mapping updates, and waiting for active shards.final ReindexRequest.BuilderThe number of shard copies that must be active before proceeding with the operation.final ReindexRequest.BuilderThe number of shard copies that must be active before proceeding with the operation.final ReindexRequest.BuilderwaitForCompletion(Boolean value) Iftrue, the request blocks until the operation is complete.Methods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJsonMethods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
conflicts
Indicates whether to continue reindexing even when there are conflicts.API name:
conflicts -
dest
Required - The destination you are copying to.API name:
dest -
dest
public final ReindexRequest.Builder dest(Function<Destination.Builder, ObjectBuilder<Destination>> fn) Required - The destination you are copying to.API name:
dest -
maxDocs
The maximum number of documents to reindex. By default, all documents are reindexed. If it is a value less then or equal toscroll_size, a scroll will not be used to retrieve the results for the operation.If
conflictsis set toproceed, the reindex operation could attempt to reindex more documents from the source thanmax_docsuntil it has successfully indexedmax_docsdocuments into the target or it has gone through every document in the source query.API name:
max_docs -
refresh
Iftrue, the request refreshes affected shards to make this operation visible to search.API name:
refresh -
requestsPerSecond
The throttle for this request in sub-requests per second. By default, there is no throttle.API name:
requests_per_second -
requireAlias
Iftrue, the destination must be an index alias.API name:
require_alias -
script
The script to run to update the document source or metadata when reindexing.API name:
script -
script
The script to run to update the document source or metadata when reindexing.API name:
script -
scroll
The period of time that a consistent view of the index should be maintained for scrolled search.API name:
scroll -
scroll
The period of time that a consistent view of the index should be maintained for scrolled search.API name:
scroll -
slices
The number of slices this task should be divided into. It defaults to one slice, which means the task isn't sliced into subtasks.Reindex supports sliced scroll to parallelize the reindexing process. This parallelization can improve efficiency and provide a convenient way to break the request down into smaller parts.
NOTE: Reindexing from remote clusters does not support manual or automatic slicing.
If set to
auto, Elasticsearch chooses the number of slices to use. This setting will use one slice per shard, up to a certain limit. If there are multiple sources, it will choose the number of slices based on the index or backing index with the smallest number of shards.API name:
slices -
slices
The number of slices this task should be divided into. It defaults to one slice, which means the task isn't sliced into subtasks.Reindex supports sliced scroll to parallelize the reindexing process. This parallelization can improve efficiency and provide a convenient way to break the request down into smaller parts.
NOTE: Reindexing from remote clusters does not support manual or automatic slicing.
If set to
auto, Elasticsearch chooses the number of slices to use. This setting will use one slice per shard, up to a certain limit. If there are multiple sources, it will choose the number of slices based on the index or backing index with the smallest number of shards.API name:
slices -
source
Required - The source you are copying from.API name:
source -
source
Required - The source you are copying from.API name:
source -
timeout
The period each indexing waits for automatic index creation, dynamic mapping updates, and waiting for active shards. By default, Elasticsearch waits for at least one minute before failing. The actual wait time could be longer, particularly when multiple waits occur.API name:
timeout -
timeout
The period each indexing waits for automatic index creation, dynamic mapping updates, and waiting for active shards. By default, Elasticsearch waits for at least one minute before failing. The actual wait time could be longer, particularly when multiple waits occur.API name:
timeout -
waitForActiveShards
The number of shard copies that must be active before proceeding with the operation. Set it toallor any positive integer up to the total number of shards in the index (number_of_replicas+1). The default value is one, which means it waits for each primary shard to be active.API name:
wait_for_active_shards -
waitForActiveShards
public final ReindexRequest.Builder waitForActiveShards(Function<WaitForActiveShards.Builder, ObjectBuilder<WaitForActiveShards>> fn) The number of shard copies that must be active before proceeding with the operation. Set it toallor any positive integer up to the total number of shards in the index (number_of_replicas+1). The default value is one, which means it waits for each primary shard to be active.API name:
wait_for_active_shards -
waitForCompletion
Iftrue, the request blocks until the operation is complete.API name:
wait_for_completion -
self
- Specified by:
selfin classRequestBase.AbstractBuilder<ReindexRequest.Builder>
-
build
Builds aReindexRequest.- Specified by:
buildin interfaceObjectBuilder<ReindexRequest>- Throws:
NullPointerException- if some of the required fields are null.
-