Hi;
Elasticsearch version: 8.6.2
Logstash version: 8.6.2
I have created and tested at simple ingest pipeline, which adds an event.ingested field to Filebeat documents, which do not already have this field set by other Filebeat pipelines.
All events are received by Logstash before ingestion into Elasticsearch ingestion nodes.
The pipeline is configured like this:
{
"set_event_ingested": {
"description": "Add a event.ingested field to filebeat events with the value _ingest.timestamp if the field is not set in the document",
"processors": [
{
"set": {
"field": "event.ingested",
"value": "{{_ingest.timestamp}}",
"if": "ctx?.agent?.type == 'filebeat' && !ctx.containsKey('event.ingested')"
}
}
],
"version": 1,
"on_failure": [
{
"append": {
"field": "error.message",
"value": [
"{{ _ingest.on_failure_message }}"
]
}
}
]
}
}
I have tested the pipeline from Kibana with documents which fulfill the conditions and other documents which do not fulfill the conditions. The pipeline works as expected.
However looking in nodes/stats it is seen the pipeline never executes:
"set_event_ingested": {
"count": 0,
"time_in_millis": 0,
"current": 0,
"failed": 0,
"processors": [
{
"set": {
"type": "conditional",
"stats": {
"count": 0,
"time_in_millis": 0,
"current": 0,
"failed": 0
}
}
}
]
},
I have search other blog posts for similar problems, but cannot find a solution.
I have loaded many filebeat pipelines into Elasticsearch, so with the default pipelines around 200 ingest pipelines are loaded. However, several of these pipelines do not process any data events, since the beats have been upgraded from version 7.15 to 7.17.
Could this impact the ingest pipeline I have created? How can I force Elasticsearch to apply the set_event_ingested to all filebeat documents, which fulfill the conditions?
Best regards
Flemming