/ Apr 1st, 2020 /

More Condition Predicates

More options when filtering and routing events

Vector has a concept "conditions" that are used to qualify events. For example, this is used in Vector's unit testing feature, swimlanes transform, and filter transform. This change adds new predicates that enable powerful matching and condition expression. Specifically, the following predicates were added:

  • begins_with
  • contains
  • ends_with
  • is_log
  • is_metric
  • regex

Example

For example, you can filter all messages that contain the error term with the new contains predicate:

[transforms.errors]
type = "filter"
condition."message.cotnain" = "error"

The world is your oyster.

Get This Change

This change was made available in 0.9.0. You can get this change by downloading the latest stable release.

Like What You See?