When trying to filter out noise from event logs, the pipeline rules seem as excellent option, as complex conditions are available.
When setting up noise reduction pipeline, it would seem logical to make the most voluminous drops at stage 0, and then have less messages to process in later stages.
At the moment, there are two things that happen
rule "empty"
when
(1 == 1)
then
end
processing does not continue to the next stages for the messages that are not dropped.
Two suggestions:
@jtkkex depending on your conditions the fastest possible solution would be to have multiple conditions:
alert "multi con"
when
has_field("EventID") AND
to_string($message.eventid) == 4662 OR
to_string($message.eventid) == 4672 OR
to_string($message.eventid) == 4662
then
drop_message();
end
Currently your suggestion would be against the design principles of the processing pipelines that you need to select on purpose what is processed and what not.
Actually, I do use multiple conditions. The "problem" is that after drop_message(), the processing of the message does not stop. So having stage 0 drop messages that are not wanted and then stage 1 processing fields of (also) the dropped messages is so unnecessary. If for example 2000 msgs/s are processed at stage 0. 90% of them are dropped. Then at stage 1, again 2000 msgs/s are processed, in stead of the 200msg/s that would seem logical to me.
This looks more like a bug and we will take a look at it.
Hi @jalogisch @florianvolle
I am facing the similar issue in my env where graylog is running 3.1.1 version. Let us know if there is any update on this request.
Thanks,
Ganeshbabu R
Beyond drop_message(), It would be helpful to have a separate exit_pipeline() function to reduce unnecessary processing and/or pipeline stages. Being able to set rule execution sequence within a stage would help too... but is slightly off topic.
@tmacgbay you might want to open a feature request for that function.