Reputation: 3699
For example, my logs look like:
{
"fieldA":"logA",
"foo":"bar"
}
or
{
"fieldA":"logA",
"fieldB":"logB"
}
In my case, I only want logs with field "foo" to be collected, while dropping other logs.
Upvotes: 1
Views: 5005
Reputation: 3699
Use grep
filter plugin to only include events with foo
field:
[FILTER]
Name grep
Match *
Regex foo .*
Upvotes: 0