Hi,
I am fixing bigger logstash config file where I have custom grok patterns but that is just tip of the iceberg regarding my problems.
In Filebeat I have multiple log files and some of them (their log events) are visible in Kibana ok, and some not because their content ends up in the message field. Some log events are not even visible in Kibana when I try to filter it by tags in Kibana.
I can fix stuff if I have one IF statement but when multiple IF statements are involved I am not sure what is the culprit besides maybe Filebeat being slow or my custom grok patterns are not so good or both?
I have no problem with fixing logstash grok patterns but multiple IF statemens I have a problem with.
You can see the simple apache example I was resolving with the help of Larry on the following link: Kibana not showing dictionary output of log events
I can suspect that it takes time for Filebeat to send stuff to Elasticsearch through Logstash but just want to make sure if following is legit in logstash-config file.
if "something-1" in [tags] {
grok {
}
}
.
.
.
if "something-2" in [tags] {
grok {
}
}
.
.
.
if "something-N" in [tags] {
grok {
}
}
I have this set multiple times i.e. I have multiple if conditions set like that. So, was wondering if that is ok by logstash or I should include else if as well?
Not sure how logstash checks multiple if statements, like programming or it checks them all and if they match I get output?
What I want to achieve is that all of those if statements execute because I have to see all log files in Kibana i.e. their log events. If there is a smarter way to do it without IF I would appreciate some direction.