younifyd
Menu

Update data stream lifecycles

Update data stream lifecycles

PUT/_data_stream/{name}/_lifecycle

Use it in a workflow

  1. Add a step and choose the Elasticsearch connector.
  2. Pick the Update data stream lifecycles action (under data stream).
  3. Fill in the fields below, then reference the result from later steps as {{updateDataStreamLifecycles.response.data}}.

Request

Path parameters

nameoneOfrequired

Comma-separated list of data streams used to limit the request. Supports wildcards (`*`). To target all data streams use `*` or `_all`.

Query parameters

expand_wildcardsoneOf

Type of data stream that wildcard patterns can match. Supports comma-separated values, such as `open,hidden`.

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.

Request body

Enter the body as JSON in the step's Body field.

data_retentionany

If defined, every document added to this data stream will be stored at least for this time frame. Any time after this duration the document could be deleted. When empty, every document in this data stream will be stored indefinitely.

downsamplingarray<object>

The downsampling configuration to execute for the managed backing index after rollover.

afteranyrequired

The duration since rollover when this downsampling round should execute

fixed_intervalanyrequired

The downsample interval.

downsampling_methodany

The method used to downsample the data. There are two options `aggregate` and `last_value`. It requires `downsampling` to be defined. Defaults to `aggregate`.

enabledboolean

If defined, it turns data stream lifecycle on/off (`true`/`false`) for this data stream. A data stream lifecycle that's disabled (enabled: `false`) will have no effect on the data stream.

Default true

json
{
  "data_retention": null,
  "downsampling": [
    {
      "after": null,
      "fixed_interval": null
    }
  ],
  "downsampling_method": null,
  "enabled": true
}

Response

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

acknowledgedboolean

For a successful response, this value is always true. On failure, an exception is returned instead.

json
{
  "acknowledged": false
}

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

Update data stream lifecycles — Elasticsearch — Documentation