Switch
A switch node is used to filter log records based on a given condition. Only log records matching the condition will be passed to the next nodes, while others will be discarded.
NB: The language used to write conditions is Expr.
Example
{
"timestamp": "...",
"fields": {
"tag": "myapp",
"content": "hello world"
}
}
⇓
⇓
{
"timestamp": "...",
"fields": {
"tag": "myapp",
"content": "hello world"
}
}
{
"timestamp": "...",
"fields": {
"tag": "notmyapp",
"content": "hello world"
}
}
⇓
⇓
☓