Hello
I am facing an issue with Elastisearch Query DSL while using a prefix filter for the "log_message" field.
The goal is to display logs where the "log_message" field has a prefix of "Started". However, the filter is also including lines where "Started" appears in the middle of the message, not just at the beginning.
Here's my query:
{
"prefix": {
"log_message": "started"
}
}
Here's my log message:
2023-11-20 10:49:34.445 | INFO | [restartedMain] --- 14348 | o.a.c.impl.engine.AbstractCamelContext | | Started SEND_AGENT_REF_TO_S3<2> (direct://agentRefFromSiCas2-3)
You can adjust your Logstash grok pattern to split the "log_message" field into two separate fields: one for the "| |" part and one for the actual log message. Here's an example of how you can adjust your Logstash pattern:
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.