Skip to content

Best way to drop an event #23045

Answered by satellite-no
Bouska asked this question in Q&A
May 14, 2025 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

You have a couple of options here, before you transform the data I would use an exclusive route to split the streams, then you have one stream far process and another far kernel and you can process the data as expected.

example

type: exclusive_route
inputs:
  - '*'
routes:
  - name: "kernel"
    condition: match(to_string!(.message), r'parse_kernel_log')
  - name: "process"
     condition: match(to_string!(.message), r'parse_process_log')

Alternatively, you could convert to one remap and try to process the data on error.

example

transforms:
  parse_kernel_log:
    type: "remap"
    inputs: ["*_extract_log"]
    drop_on_error: true
    source: |
      ., err |= parse_regex(.message, r'^\[(…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@Bouska
Comment options

Answer selected by pront
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
transform: remap Anything `remap` transform related
2 participants