Class BulkRequest
java.lang.Object
co.elastic.clients.elasticsearch._types.RequestBase
co.elastic.clients.elasticsearch.core.BulkRequest
- All Implemented Interfaces:
JsonpSerializable,NdJsonpSerializable
Performs multiple indexing or delete operations in a single API call. This
reduces overhead and can greatly increase indexing speed.
- 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 Endpoint<BulkRequest,BulkResponse, ErrorResponse> Endpoint "bulk". -
Method Summary
Modifier and TypeMethodDescriptionIterator<?>final Stringindex()Name of the data stream, index, or index alias to perform bulk actions on.static BulkRequestfinal List<BulkOperation>Required - Request body.final Stringpipeline()ID of the pipeline to use to preprocess incoming documents.final Refreshrefresh()Iftrue, Elasticsearch refreshes the affected shards to make this operation visible to search, ifwait_forthen wait for a refresh to make this operation visible to search, iffalsedo nothing with refreshes.final BooleanIftrue, the request’s actions must target an index alias.final Stringrouting()Custom value used to route operations to a specific shard.voidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) Serialize this value to JSON.final SourceConfigParamsource()trueorfalseto return the_sourcefield or not, or a list of fields to return.A comma-separated list of source fields to exclude from the response.A comma-separated list of source fields to include in the response.final Timetimeout()Period each action waits for the following operations: automatic index creation, dynamic mapping updates, waiting for active shards.final WaitForActiveShardsThe number of shard copies that must be active before proceeding with the operation.Methods inherited from class co.elastic.clients.elasticsearch._types.RequestBase
toString
-
Field Details
-
_ENDPOINT
Endpoint "bulk".
-
-
Method Details
-
of
-
_serializables
- Specified by:
_serializablesin interfaceNdJsonpSerializable
-
source
trueorfalseto return the_sourcefield or not, or a list of fields to return.API name:
_source -
sourceExcludes
A comma-separated list of source fields to exclude from the response.API name:
_source_excludes -
sourceIncludes
A comma-separated list of source fields to include in the response.API name:
_source_includes -
index
Name of the data stream, index, or index alias to perform bulk actions on.API name:
index -
pipeline
ID of the pipeline to use to preprocess incoming documents. If the index has a default ingest pipeline specified, then setting the value to_nonedisables the default ingest pipeline for this request. If a final pipeline is configured it will always run, regardless of the value of this parameter.API name:
pipeline -
refresh
Iftrue, Elasticsearch refreshes the affected shards to make this operation visible to search, ifwait_forthen wait for a refresh to make this operation visible to search, iffalsedo nothing with refreshes. Valid values:true,false,wait_for.API name:
refresh -
requireAlias
Iftrue, the request’s actions must target an index alias.API name:
require_alias -
routing
Custom value used to route operations to a specific shard.API name:
routing -
timeout
Period each action waits for the following operations: automatic index creation, dynamic mapping updates, waiting for active shards.API name:
timeout -
waitForActiveShards
The number of shard copies that must be active before proceeding with the operation. Set to all or any positive integer up to the total number of shards in the index (number_of_replicas+1).API name:
wait_for_active_shards -
operations
Required - Request body. -
serialize
Serialize this value to JSON.- Specified by:
serializein interfaceJsonpSerializable
-