diff --git a/modules/openstack_project/files/logstash/log-pusher.py b/modules/openstack_project/files/logstash/log-pusher.py index a613f90a7f..8b04810e7a 100644 --- a/modules/openstack_project/files/logstash/log-pusher.py +++ b/modules/openstack_project/files/logstash/log-pusher.py @@ -133,6 +133,7 @@ class LogRetriever(threading.Thread): def _parse_fields(self, event): fields = {} + fields["filename"] = self.filename fields["build_name"] = event.get("name", "UNKNOWN") fields["build_status"] = event["build"].get("status", "UNKNOWN") fields["build_number"] = event["build"].get("number", "UNKNOWN") diff --git a/modules/openstack_project/templates/logstash/indexer.conf.erb b/modules/openstack_project/templates/logstash/indexer.conf.erb index 3cc97a4750..0adf897f4a 100644 --- a/modules/openstack_project/templates/logstash/indexer.conf.erb +++ b/modules/openstack_project/templates/logstash/indexer.conf.erb @@ -32,6 +32,7 @@ filter { negate => true pattern => "^%{DATESTAMP} \|" what => "previous" + stream_identity => "%{@source_host}.%{filename}" } multiline { type => "jenkins" @@ -39,6 +40,7 @@ filter { negate => true pattern => "^%{DATESTAMP} " what => "previous" + stream_identity => "%{@source_host}.%{filename}" } grok { type => "jenkins"