Move to Lifecycle Step APIedit

Warning

This functionality is in beta and is subject to change. The design and code is less mature than official GA features and is being provided as-is with no warranties. Beta features are not subject to the support SLA of official GA features.

Triggers execution of a specific step in the lifecycle policy.

Requestedit

POST _ilm/move/<index>

Descriptionedit

Warning

This operation can result in the loss of data. Manually moving an index into a specific step executes that step even if it has already been performed. This is a potentially destructive action and this should be considered an expert level API.

Manually moves an index into the specified step and executes that step. You must specify both the current step and the step to be executed in the body of the request.

The request will fail if the current step does not match the step currently being executed for the index. This is to prevent the index from being moved from an unexpected step into the next step.

Path Parametersedit

index (required)
(string) Identifier for the index.

Request Parametersedit

timeout
(time units) Specifies the period of time to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. Defaults to 30s. For more information about time units, see Time unitsedit.
master_timeout
(time units) Specifies the period of time 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. Defaults to 30s. For more information about time units, see Time unitsedit.

Authorizationedit

You must have the manage privilege on the indices being managed to use this API. For more information, see Security Privileges.

Examplesedit

The following example moves my_index from the initial step to the forcemerge step:

POST _ilm/move/my_index
{
  "current_step": { 
    "phase": "new",
    "action": "complete",
    "name": "complete"
  },
  "next_step": { 
    "phase": "warm",
    "action": "forcemerge",
    "name": "forcemerge"
  }
}

The step that the index is expected to be in

The step that you want to execute

If the request succeeds, you receive the following result:

{
  "acknowledged": true
}

The request will fail if the index is not in the new phase as specified by the current_step.