Class UpdateByQueryRequest.Builder
- java.lang.Object
-
- org.opensearch.client.util.ObjectBuilderBase
-
- org.opensearch.client.opensearch.core.UpdateByQueryRequest.Builder
-
- All Implemented Interfaces:
ObjectBuilder<UpdateByQueryRequest>
- Enclosing class:
- UpdateByQueryRequest
public static class UpdateByQueryRequest.Builder extends ObjectBuilderBase implements ObjectBuilder<UpdateByQueryRequest>
Builder forUpdateByQueryRequest.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UpdateByQueryRequest.BuilderallowNoIndices(java.lang.Boolean value)Whether to ignore if a wildcard indices expression resolves into no concrete indices.UpdateByQueryRequest.Builderanalyzer(java.lang.String value)The analyzer to use for the query stringUpdateByQueryRequest.BuilderanalyzeWildcard(java.lang.Boolean value)Specify whether wildcard and prefix queries should be analyzed (default: false)UpdateByQueryRequestbuild()Builds aUpdateByQueryRequest.UpdateByQueryRequest.Builderconflicts(Conflicts value)API name:conflictsUpdateByQueryRequest.BuilderdefaultOperator(Operator value)The default operator for query string query (AND or OR)UpdateByQueryRequest.Builderdf(java.lang.String value)The field to use as default where no field prefix is given in the query stringUpdateByQueryRequest.BuilderexpandWildcards(java.util.List<ExpandWildcard> list)Whether to expand wildcard expression to concrete indices that are open, closed or both.UpdateByQueryRequest.BuilderexpandWildcards(ExpandWildcard value, ExpandWildcard... values)Whether to expand wildcard expression to concrete indices that are open, closed or both.UpdateByQueryRequest.Builderfrom(java.lang.Long value)Starting offset (default: 0)UpdateByQueryRequest.BuilderignoreUnavailable(java.lang.Boolean value)Whether specified concrete indices should be ignored when unavailable (missing or closed)UpdateByQueryRequest.Builderindex(java.lang.String value, java.lang.String... values)Required - A comma-separated list of index names to search; use_allor empty string to perform the operation on all indicesUpdateByQueryRequest.Builderindex(java.util.List<java.lang.String> list)Required - A comma-separated list of index names to search; use_allor empty string to perform the operation on all indicesUpdateByQueryRequest.Builderlenient(java.lang.Boolean value)Specify whether format-based query failures (such as providing text to a numeric field) should be ignoredUpdateByQueryRequest.BuildermaxDocs(java.lang.Long value)API name:max_docsUpdateByQueryRequest.Builderpipeline(java.lang.String value)Ingest pipeline to set on index requests made by this action.UpdateByQueryRequest.Builderpreference(java.lang.String value)Specify the node or shard the operation should be performed on (default: random)UpdateByQueryRequest.Builderquery(java.util.function.Function<Query.Builder,ObjectBuilder<Query>> fn)API name:queryUpdateByQueryRequest.Builderquery(Query value)API name:queryUpdateByQueryRequest.Builderrefresh(java.lang.Boolean value)Should the affected indexes be refreshed?UpdateByQueryRequest.BuilderrequestCache(java.lang.Boolean value)Specify if request cache should be used for this request or not, defaults to index level settingUpdateByQueryRequest.BuilderrequestsPerSecond(java.lang.Long value)The throttle to set on this request in sub-requests per second.UpdateByQueryRequest.Builderrouting(java.lang.String value)A comma-separated list of specific routing valuesUpdateByQueryRequest.Builderscript(java.util.function.Function<Script.Builder,ObjectBuilder<Script>> fn)API name:scriptUpdateByQueryRequest.Builderscript(Script value)API name:scriptUpdateByQueryRequest.Builderscroll(java.util.function.Function<Time.Builder,ObjectBuilder<Time>> fn)Specify how long a consistent view of the index should be maintained for scrolled searchUpdateByQueryRequest.Builderscroll(Time value)Specify how long a consistent view of the index should be maintained for scrolled searchUpdateByQueryRequest.BuilderscrollSize(java.lang.Long value)Size on the scroll request powering the update by queryUpdateByQueryRequest.BuildersearchTimeout(java.util.function.Function<Time.Builder,ObjectBuilder<Time>> fn)Explicit timeout for each search request.UpdateByQueryRequest.BuildersearchTimeout(Time value)Explicit timeout for each search request.UpdateByQueryRequest.BuildersearchType(SearchType value)Search operation typeUpdateByQueryRequest.Buildersize(java.lang.Long value)Deprecated, please usemax_docsinsteadUpdateByQueryRequest.Builderslice(java.util.function.Function<SlicedScroll.Builder,ObjectBuilder<SlicedScroll>> fn)API name:sliceUpdateByQueryRequest.Builderslice(SlicedScroll value)API name:sliceUpdateByQueryRequest.Builderslices(java.lang.Long value)The number of slices this task should be divided into.UpdateByQueryRequest.Buildersort(java.lang.String value, java.lang.String... values)A comma-separated list of <field>:<direction> pairsUpdateByQueryRequest.Buildersort(java.util.List<java.lang.String> list)A comma-separated list of <field>:<direction> pairsUpdateByQueryRequest.Buildersource(java.util.function.Function<SourceConfigParam.Builder,ObjectBuilder<SourceConfigParam>> fn)True or false to return the _source field or not, or a list of fields to returnUpdateByQueryRequest.Buildersource(SourceConfigParam value)True or false to return the _source field or not, or a list of fields to returnUpdateByQueryRequest.BuildersourceExcludes(java.lang.String value, java.lang.String... values)A list of fields to exclude from the returned _source fieldUpdateByQueryRequest.BuildersourceExcludes(java.util.List<java.lang.String> list)A list of fields to exclude from the returned _source fieldUpdateByQueryRequest.BuildersourceIncludes(java.lang.String value, java.lang.String... values)A list of fields to extract and return from the _source fieldUpdateByQueryRequest.BuildersourceIncludes(java.util.List<java.lang.String> list)A list of fields to extract and return from the _source fieldUpdateByQueryRequest.Builderstats(java.lang.String value, java.lang.String... values)Specific 'tag' of the request for logging and statistical purposesUpdateByQueryRequest.Builderstats(java.util.List<java.lang.String> list)Specific 'tag' of the request for logging and statistical purposesUpdateByQueryRequest.BuilderterminateAfter(java.lang.Long value)The maximum number of documents to collect for each shard, upon reaching which the query execution will terminate early.UpdateByQueryRequest.Buildertimeout(java.util.function.Function<Time.Builder,ObjectBuilder<Time>> fn)Time each individual bulk request should wait for shards that are unavailable.UpdateByQueryRequest.Buildertimeout(Time value)Time each individual bulk request should wait for shards that are unavailable.UpdateByQueryRequest.Builderversion(java.lang.Boolean value)Specify whether to return document version as part of a hitUpdateByQueryRequest.BuilderversionType(java.lang.Boolean value)Should the document increment the version number (internal) on hit or not (reindex)UpdateByQueryRequest.BuilderwaitForActiveShards(java.util.function.Function<WaitForActiveShards.Builder,ObjectBuilder<WaitForActiveShards>> fn)Sets the number of shard copies that must be active before proceeding with the update by query operation.UpdateByQueryRequest.BuilderwaitForActiveShards(WaitForActiveShards value)Sets the number of shard copies that must be active before proceeding with the update by query operation.UpdateByQueryRequest.BuilderwaitForCompletion(java.lang.Boolean value)Should the request should block until the update by query operation is complete.-
Methods inherited from class org.opensearch.client.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
-
-
-
Method Detail
-
source
public final UpdateByQueryRequest.Builder source(@Nullable SourceConfigParam value)
True or false to return the _source field or not, or a list of fields to returnAPI name:
_source
-
source
public final UpdateByQueryRequest.Builder source(java.util.function.Function<SourceConfigParam.Builder,ObjectBuilder<SourceConfigParam>> fn)
True or false to return the _source field or not, or a list of fields to returnAPI name:
_source
-
sourceExcludes
public final UpdateByQueryRequest.Builder sourceExcludes(java.util.List<java.lang.String> list)
A list of fields to exclude from the returned _source fieldAPI name:
_source_excludesAdds all elements of
listtosourceExcludes.
-
sourceExcludes
public final UpdateByQueryRequest.Builder sourceExcludes(java.lang.String value, java.lang.String... values)
A list of fields to exclude from the returned _source fieldAPI name:
_source_excludesAdds one or more values to
sourceExcludes.
-
sourceIncludes
public final UpdateByQueryRequest.Builder sourceIncludes(java.util.List<java.lang.String> list)
A list of fields to extract and return from the _source fieldAPI name:
_source_includesAdds all elements of
listtosourceIncludes.
-
sourceIncludes
public final UpdateByQueryRequest.Builder sourceIncludes(java.lang.String value, java.lang.String... values)
A list of fields to extract and return from the _source fieldAPI name:
_source_includesAdds one or more values to
sourceIncludes.
-
allowNoIndices
public final UpdateByQueryRequest.Builder allowNoIndices(@Nullable java.lang.Boolean value)
Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes_allstring or when no indices have been specified)API name:
allow_no_indices
-
analyzeWildcard
public final UpdateByQueryRequest.Builder analyzeWildcard(@Nullable java.lang.Boolean value)
Specify whether wildcard and prefix queries should be analyzed (default: false)API name:
analyze_wildcard
-
analyzer
public final UpdateByQueryRequest.Builder analyzer(@Nullable java.lang.String value)
The analyzer to use for the query stringAPI name:
analyzer
-
conflicts
public final UpdateByQueryRequest.Builder conflicts(@Nullable Conflicts value)
API name:conflicts
-
defaultOperator
public final UpdateByQueryRequest.Builder defaultOperator(@Nullable Operator value)
The default operator for query string query (AND or OR)API name:
default_operator
-
df
public final UpdateByQueryRequest.Builder df(@Nullable java.lang.String value)
The field to use as default where no field prefix is given in the query stringAPI name:
df
-
expandWildcards
public final UpdateByQueryRequest.Builder expandWildcards(java.util.List<ExpandWildcard> list)
Whether to expand wildcard expression to concrete indices that are open, closed or both.API name:
expand_wildcardsAdds all elements of
listtoexpandWildcards.
-
expandWildcards
public final UpdateByQueryRequest.Builder expandWildcards(ExpandWildcard value, ExpandWildcard... values)
Whether to expand wildcard expression to concrete indices that are open, closed or both.API name:
expand_wildcardsAdds one or more values to
expandWildcards.
-
from
public final UpdateByQueryRequest.Builder from(@Nullable java.lang.Long value)
Starting offset (default: 0)API name:
from
-
ignoreUnavailable
public final UpdateByQueryRequest.Builder ignoreUnavailable(@Nullable java.lang.Boolean value)
Whether specified concrete indices should be ignored when unavailable (missing or closed)API name:
ignore_unavailable
-
index
public final UpdateByQueryRequest.Builder index(java.util.List<java.lang.String> list)
Required - A comma-separated list of index names to search; use_allor empty string to perform the operation on all indicesAPI name:
indexAdds all elements of
listtoindex.
-
index
public final UpdateByQueryRequest.Builder index(java.lang.String value, java.lang.String... values)
Required - A comma-separated list of index names to search; use_allor empty string to perform the operation on all indicesAPI name:
indexAdds one or more values to
index.
-
lenient
public final UpdateByQueryRequest.Builder lenient(@Nullable java.lang.Boolean value)
Specify whether format-based query failures (such as providing text to a numeric field) should be ignoredAPI name:
lenient
-
maxDocs
public final UpdateByQueryRequest.Builder maxDocs(@Nullable java.lang.Long value)
API name:max_docs
-
pipeline
public final UpdateByQueryRequest.Builder pipeline(@Nullable java.lang.String value)
Ingest pipeline to set on index requests made by this action. (default: none)API name:
pipeline
-
preference
public final UpdateByQueryRequest.Builder preference(@Nullable java.lang.String value)
Specify the node or shard the operation should be performed on (default: random)API name:
preference
-
query
public final UpdateByQueryRequest.Builder query(@Nullable Query value)
API name:query
-
query
public final UpdateByQueryRequest.Builder query(java.util.function.Function<Query.Builder,ObjectBuilder<Query>> fn)
API name:query
-
refresh
public final UpdateByQueryRequest.Builder refresh(@Nullable java.lang.Boolean value)
Should the affected indexes be refreshed?API name:
refresh
-
requestCache
public final UpdateByQueryRequest.Builder requestCache(@Nullable java.lang.Boolean value)
Specify if request cache should be used for this request or not, defaults to index level settingAPI name:
request_cache
-
requestsPerSecond
public final UpdateByQueryRequest.Builder requestsPerSecond(@Nullable java.lang.Long value)
The throttle to set on this request in sub-requests per second. -1 means no throttle.API name:
requests_per_second
-
routing
public final UpdateByQueryRequest.Builder routing(@Nullable java.lang.String value)
A comma-separated list of specific routing valuesAPI name:
routing
-
script
public final UpdateByQueryRequest.Builder script(@Nullable Script value)
API name:script
-
script
public final UpdateByQueryRequest.Builder script(java.util.function.Function<Script.Builder,ObjectBuilder<Script>> fn)
API name:script
-
scroll
public final UpdateByQueryRequest.Builder scroll(@Nullable Time value)
Specify how long a consistent view of the index should be maintained for scrolled searchAPI name:
scroll
-
scroll
public final UpdateByQueryRequest.Builder scroll(java.util.function.Function<Time.Builder,ObjectBuilder<Time>> fn)
Specify how long a consistent view of the index should be maintained for scrolled searchAPI name:
scroll
-
scrollSize
public final UpdateByQueryRequest.Builder scrollSize(@Nullable java.lang.Long value)
Size on the scroll request powering the update by queryAPI name:
scroll_size
-
searchTimeout
public final UpdateByQueryRequest.Builder searchTimeout(@Nullable Time value)
Explicit timeout for each search request. Defaults to no timeout.API name:
search_timeout
-
searchTimeout
public final UpdateByQueryRequest.Builder searchTimeout(java.util.function.Function<Time.Builder,ObjectBuilder<Time>> fn)
Explicit timeout for each search request. Defaults to no timeout.API name:
search_timeout
-
searchType
public final UpdateByQueryRequest.Builder searchType(@Nullable SearchType value)
Search operation typeAPI name:
search_type
-
size
public final UpdateByQueryRequest.Builder size(@Nullable java.lang.Long value)
Deprecated, please usemax_docsinsteadAPI name:
size
-
slice
public final UpdateByQueryRequest.Builder slice(@Nullable SlicedScroll value)
API name:slice
-
slice
public final UpdateByQueryRequest.Builder slice(java.util.function.Function<SlicedScroll.Builder,ObjectBuilder<SlicedScroll>> fn)
API name:slice
-
slices
public final UpdateByQueryRequest.Builder slices(@Nullable java.lang.Long value)
The number of slices this task should be divided into. Defaults to 1, meaning the task isn't sliced into subtasks. Can be set to 0 forauto.API name:
slices
-
sort
public final UpdateByQueryRequest.Builder sort(java.util.List<java.lang.String> list)
A comma-separated list of <field>:<direction> pairsAPI name:
sortAdds all elements of
listtosort.
-
sort
public final UpdateByQueryRequest.Builder sort(java.lang.String value, java.lang.String... values)
A comma-separated list of <field>:<direction> pairsAPI name:
sortAdds one or more values to
sort.
-
stats
public final UpdateByQueryRequest.Builder stats(java.util.List<java.lang.String> list)
Specific 'tag' of the request for logging and statistical purposesAPI name:
statsAdds all elements of
listtostats.
-
stats
public final UpdateByQueryRequest.Builder stats(java.lang.String value, java.lang.String... values)
Specific 'tag' of the request for logging and statistical purposesAPI name:
statsAdds one or more values to
stats.
-
terminateAfter
public final UpdateByQueryRequest.Builder terminateAfter(@Nullable java.lang.Long value)
The maximum number of documents to collect for each shard, upon reaching which the query execution will terminate early.API name:
terminate_after
-
timeout
public final UpdateByQueryRequest.Builder timeout(@Nullable Time value)
Time each individual bulk request should wait for shards that are unavailable.API name:
timeout
-
timeout
public final UpdateByQueryRequest.Builder timeout(java.util.function.Function<Time.Builder,ObjectBuilder<Time>> fn)
Time each individual bulk request should wait for shards that are unavailable.API name:
timeout
-
version
public final UpdateByQueryRequest.Builder version(@Nullable java.lang.Boolean value)
Specify whether to return document version as part of a hitAPI name:
version
-
versionType
public final UpdateByQueryRequest.Builder versionType(@Nullable java.lang.Boolean value)
Should the document increment the version number (internal) on hit or not (reindex)API name:
version_type
-
waitForActiveShards
public final UpdateByQueryRequest.Builder waitForActiveShards(@Nullable WaitForActiveShards value)
Sets the number of shard copies that must be active before proceeding with the update by query operation. Defaults to 1, meaning the primary shard only. Set toallfor all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1)API name:
wait_for_active_shards
-
waitForActiveShards
public final UpdateByQueryRequest.Builder waitForActiveShards(java.util.function.Function<WaitForActiveShards.Builder,ObjectBuilder<WaitForActiveShards>> fn)
Sets the number of shard copies that must be active before proceeding with the update by query operation. Defaults to 1, meaning the primary shard only. Set toallfor all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1)API name:
wait_for_active_shards
-
waitForCompletion
public final UpdateByQueryRequest.Builder waitForCompletion(@Nullable java.lang.Boolean value)
Should the request should block until the update by query operation is complete.API name:
wait_for_completion
-
build
public UpdateByQueryRequest build()
Builds aUpdateByQueryRequest.- Specified by:
buildin interfaceObjectBuilder<UpdateByQueryRequest>- Throws:
java.lang.NullPointerException- if some of the required fields are null.
-
-