Class Source
java.lang.Object
co.elastic.clients.elasticsearch.core.reindex.Source
- All Implemented Interfaces:
JsonpSerializable
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final JsonpDeserializer<Source>
Json deserializer forSource
-
Method Summary
Modifier and TypeMethodDescriptionindex()
Required - The name of the data stream, index, or alias you are copying from.static Source
final Query
query()
The documents to reindex, which is defined with Query DSL.final RemoteSource
remote()
A remote instance of Elasticsearch that you want to index from.final Map<String,
RuntimeField> API name:runtime_mappings
void
serialize
(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) Serialize this object to JSON.protected void
serializeInternal
(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) protected static void
final Integer
size()
The number of documents to index per batch.final SlicedScroll
slice()
Slice the reindex request manually using the provided slice ID and total number of slices.final List<SortOptions>
sort()
Deprecated.7.6.0Iftrue
, reindex all source fields.toString()
-
Field Details
-
_DESERIALIZER
Json deserializer forSource
-
-
Method Details
-
of
-
index
Required - The name of the data stream, index, or alias you are copying from. It accepts a comma-separated list to reindex from multiple sources.API name:
index
-
query
The documents to reindex, which is defined with Query DSL.API name:
query
-
remote
A remote instance of Elasticsearch that you want to index from.API name:
remote
-
size
The number of documents to index per batch. Use it when you are indexing from remote to ensure that the batches fit within the on-heap buffer, which defaults to a maximum size of 100 MB.API name:
size
-
slice
Slice the reindex request manually using the provided slice ID and total number of slices.API name:
slice
-
sort
Deprecated.7.6.0A comma-separated list of<field>:<direction>
pairs to sort by before indexing. Use it in conjunction withmax_docs
to control what documents are reindexed.WARNING: Sort in reindex is deprecated. Sorting in reindex was never guaranteed to index documents in order and prevents further development of reindex such as resilience and performance improvements. If used in combination with
max_docs
, consider using a query filter instead.API name:
sort
-
sourceFields
Iftrue
, reindex all source fields. Set it to a list to reindex select fields.API name:
_source
-
runtimeMappings
API name:runtime_mappings
-
serialize
Serialize this object to JSON.- Specified by:
serialize
in interfaceJsonpSerializable
-
serializeInternal
-
toString
-
setupSourceDeserializer
-