Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
If you are interested in working on this issue or have submitted a pull request, please leave a comment
Problem
it seems like the outputs.conditions needs to be true only for a single event, even if there are multiple inputs. Is this intentional? Is there a way to require the condition to be true for all of the inputs?
The example below passes the tests although one input should fail it:
> vector test
Running tests
test foo ... passed
Configuration
[sources.in]
type = "stdin"
[transforms.filter]
type = "filter"
inputs = ["in"]
condition.type = "vrl"
condition.source = """
.message == "you-shall-pass"
"""
[sinks.console]
type = "console"
inputs = ["filter"]
encoding.codec = "json"
[[tests]]
name = "foo"
# will be dropped by the filter
[[tests.inputs]]
type = "log"
insert_at = "filter"
log_fields."message" = "should-be-dropped"
[[tests.inputs]]
type = "log"
insert_at = "filter"
log_fields."message" = "you-shall-pass"
[[tests.outputs]]
extract_from = "filter"
[[tests.outputs.conditions]]
type = "vrl"
source = """
assert_eq!(.message, "you-shall-pass")
"""
A note for the community
Problem
it seems like the outputs.conditions needs to be true only for a single event, even if there are multiple inputs. Is this intentional? Is there a way to require the condition to be true for all of the inputs?
The example below passes the tests although one input should fail it:
Configuration
Version
vector 0.25.1 (x86_64-unknown-linux-gnu 9125a99 2022-11-07)
Debug Output
No response
Example Data
No response
Additional Context
No response
References
No response