Class RolloverRequest.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<BuilderT>
co.elastic.clients.elasticsearch._types.RequestBase.AbstractBuilder<RolloverRequest.Builder>
co.elastic.clients.elasticsearch.indices.RolloverRequest.Builder
- All Implemented Interfaces:
WithJson<RolloverRequest.Builder>
,ObjectBuilder<RolloverRequest>
- Enclosing class:
- RolloverRequest
public static class RolloverRequest.Builder
extends RequestBase.AbstractBuilder<RolloverRequest.Builder>
implements ObjectBuilder<RolloverRequest>
Builder for
RolloverRequest
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionfinal RolloverRequest.Builder
Required - Name of the data stream or index alias to roll over.final RolloverRequest.Builder
Aliases for the target index.final RolloverRequest.Builder
aliases
(String key, Function<Alias.Builder, ObjectBuilder<Alias>> fn) Aliases for the target index.final RolloverRequest.Builder
Aliases for the target index.build()
Builds aRolloverRequest
.final RolloverRequest.Builder
conditions
(RolloverConditions value) Conditions for the rollover.final RolloverRequest.Builder
Conditions for the rollover.final RolloverRequest.Builder
Iftrue
, checks whether the current index satisfies the specified conditions but does not perform a rollover.final RolloverRequest.Builder
mappings
(TypeMapping value) Mapping for fields in the index.final RolloverRequest.Builder
Mapping for fields in the index.final RolloverRequest.Builder
masterTimeout
(Time value) Period to wait for a connection to the master node.final RolloverRequest.Builder
Period to wait for a connection to the master node.final RolloverRequest.Builder
Name of the index to create.protected RolloverRequest.Builder
self()
final RolloverRequest.Builder
Configuration options for the index.final RolloverRequest.Builder
Configuration options for the index.final RolloverRequest.Builder
Period to wait for a response.final RolloverRequest.Builder
Period to wait for a response.final RolloverRequest.Builder
The number of shard copies that must be active before proceeding with the operation.final RolloverRequest.Builder
The number of shard copies that must be active before proceeding with the operation.Methods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJson
Methods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
alias
Required - Name of the data stream or index alias to roll over.API name:
alias
-
aliases
Aliases for the target index. Data streams do not support this parameter.API name:
aliases
Adds all entries of
map
toaliases
. -
aliases
Aliases for the target index. Data streams do not support this parameter.API name:
aliases
Adds an entry to
aliases
. -
aliases
public final RolloverRequest.Builder aliases(String key, Function<Alias.Builder, ObjectBuilder<Alias>> fn) Aliases for the target index. Data streams do not support this parameter.API name:
aliases
Adds an entry to
aliases
using a builder lambda. -
conditions
Conditions for the rollover. If specified, Elasticsearch only performs the rollover if the current index satisfies these conditions. If this parameter is not specified, Elasticsearch performs the rollover unconditionally. If conditions are specified, at least one of them must be amax_*
condition. The index will rollover if anymax_*
condition is satisfied and allmin_*
conditions are satisfied.API name:
conditions
-
conditions
public final RolloverRequest.Builder conditions(Function<RolloverConditions.Builder, ObjectBuilder<RolloverConditions>> fn) Conditions for the rollover. If specified, Elasticsearch only performs the rollover if the current index satisfies these conditions. If this parameter is not specified, Elasticsearch performs the rollover unconditionally. If conditions are specified, at least one of them must be amax_*
condition. The index will rollover if anymax_*
condition is satisfied and allmin_*
conditions are satisfied.API name:
conditions
-
dryRun
Iftrue
, checks whether the current index satisfies the specified conditions but does not perform a rollover.API name:
dry_run
-
mappings
Mapping for fields in the index. If specified, this mapping can include field names, field data types, and mapping paramaters.API name:
mappings
-
mappings
public final RolloverRequest.Builder mappings(Function<TypeMapping.Builder, ObjectBuilder<TypeMapping>> fn) Mapping for fields in the index. If specified, this mapping can include field names, field data types, and mapping paramaters.API name:
mappings
-
masterTimeout
Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error.API name:
master_timeout
-
masterTimeout
Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error.API name:
master_timeout
-
newIndex
Name of the index to create. Supports date math. Data streams do not support this parameter.API name:
new_index
-
settings
Configuration options for the index. Data streams do not support this parameter.API name:
settings
Adds all entries of
map
tosettings
. -
settings
Configuration options for the index. Data streams do not support this parameter.API name:
settings
Adds an entry to
settings
. -
timeout
Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.API name:
timeout
-
timeout
Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.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
-
waitForActiveShards
public final RolloverRequest.Builder waitForActiveShards(Function<WaitForActiveShards.Builder, ObjectBuilder<WaitForActiveShards>> fn) 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
-
self
- Specified by:
self
in classRequestBase.AbstractBuilder<RolloverRequest.Builder>
-
build
Builds aRolloverRequest
.- Specified by:
build
in interfaceObjectBuilder<RolloverRequest>
- Throws:
NullPointerException
- if some of the required fields are null.
-