younifyd
Menu

Roll over to a new index (POST /{alias}/_rollover/{new_index})

Roll over to a new index

POST/{alias}/_rollover/{new_index}

Use it in a workflow

  1. Add a step and choose the Elasticsearch connector.
  2. Pick the Roll over to a new index (POST /{alias}/_rollover/{new_index}) action (under indices).
  3. Fill in the fields below, then reference the result from later steps as {{rollOverToANewIndexPostAliasRolloverNewIndex.response.data}}.

Request

Path parameters

aliasstringrequired

Name of the data stream or index alias to roll over.

new_indexstringrequired

Name of the index to create. Supports date math. Data streams do not support this parameter.

Query parameters

dry_runboolean

If `true`, checks whether the current index satisfies the specified conditions but does not perform a rollover.

master_timeoutoneOf

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.

timeoutoneOf

Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.

wait_for_active_shardsoneOf

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`).

lazyboolean

If set to true, the rollover action will only mark a data stream to signal that it needs to be rolled over at the next write. Only allowed on data streams.

Response

Returns 200 with an object. Read it in later steps with {{rollOverToANewIndexPostAliasRolloverNewIndex.response.data.<field>}}.

acknowledgedboolean
conditionsobject
dry_runboolean
new_indexstring
old_indexstring
rolled_overboolean
shards_acknowledgedboolean
json
{
  "acknowledged": false,
  "conditions": {},
  "dry_run": false,
  "new_index": "string",
  "old_index": "string",
  "rolled_over": false,
  "shards_acknowledged": false
}

Need more? See the Elasticsearch guide for connection setup and behaviour shared by every action.

Roll over to a new index (POST /{alias}/_rollover/{new_index}) — Elasticsearch — Documentation