IBM Cloud Docs
Configuring custom multiline parsers

Configuring custom multiline parsers

If you need to introduce a new multiline parser, the additionalMultilineParsers option allows you to introduce your own multiline parsers. This will add entries to the multiline_parsers section of the Fluent Bit yaml configuration.

You must set enableMultiline to true.

For example:

enableMultiline: true

additionalMultilineParsers:
  - name: multiline_sample
    type: regex
    flush_timeout: 1000
    rules:
      - state: start_state
        regex: '/^\[\d+\/\d+\/\d+,.*$/'
        next_state: cont
      - state: cont
        regex: '/^[^\[].*$/'
        next_state: cont
      - state: cont
        regex: '/^$/'
        next_state: cont

After you modify the logs-values.yaml, you can Upgrade the agent or continue modifying the file before applying all the changes.