Append processor

Appends one or more values to an existing array if the field already exists and it is an array. Converts a scalar to an array and appends one or more values to it if the field exists and it is a scalar. Creates an array containing the provided values if the field doesn’t exist. Accepts a single value or an array of values.

Table 3. Append Options

NameRequiredDefaultDescription

field

yes

-

The field to be appended to. Supports template snippets.

value

yes

-

The value to be appended. Supports template snippets.

if

no

-

Conditionally execute this processor.

on_failure

no

-

Handle failures for this processor. See Handling Failures in Pipelines.

ignore_failure

no

false

Ignore failures for this processor. See Handling Failures in Pipelines.

tag

no

-

An identifier for this processor. Useful for debugging and metrics.

  1. {
  2. "append": {
  3. "field": "tags",
  4. "value": ["production", "{{app}}", "{{owner}}"]
  5. }
  6. }