Record Transformer

Record Transformer

Overview

Mutates/transforms incoming event streams.

Configuration

RecordTransformer

auto_typecast (bool, optional)

Use original value type.

Default: true

enable_ruby (bool, optional)

When set to true, the full Ruby syntax is enabled in the ${...} expression.

Default: false

keep_keys (string, optional)

A comma-delimited list of keys to keep.

records ([]Record, optional)

Add records docs at: https://docs.fluentd.org/filter/record_transformer Records are represented as maps: key: value

remove_keys (string, optional)

A comma-delimited list of keys to delete

renew_record (bool, optional)

Create new Hash to transform incoming data

Default: false

renew_time_key (string, optional)

Specify field name of the record to overwrite the time of events. Its value must be unix time.

Example Record Transformer filter configurations

apiVersion: logging.banzaicloud.io/v1beta1
kind: Flow
metadata:
  name: demo-flow
spec:
  filters:
    - record_transformer:
        records:
        - foo: "bar"
  selectors: {}
  localOutputRefs:
    - demo-output

Fluentd config result:

<filter **>
  @type record_transformer
  @id test_record_transformer
  <record>
    foo bar
  </record>
</filter>