Skip to content

Commit

Permalink
[Elastic Agent] Fix logging read from runnings process (elastic#18275)
Browse files Browse the repository at this point in the history
* [Elastic Agent] Fix logging read from runnings process

Since running process are using the debug level by default now, we have
a log of messages going through the log.

This commit add multiline support reading.

* Update x-pack/elastic-agent/pkg/agent/operation/monitoring.go

Co-authored-by: Michal Pristas <[email protected]>
  • Loading branch information
ph and michalpristas authored May 6, 2020
1 parent ca5995a commit 1d67ba4
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion x-pack/elastic-agent/pkg/agent/operation/monitoring.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,12 @@ func (o *Operator) getMonitoringFilebeatConfig(output interface{}) (map[string]i
"filebeat": map[string]interface{}{
"inputs": []interface{}{
map[string]interface{}{
"type": "log",
"type": "log",
"multiline": map[string]interface{}{
"pattern": "^[0-9]{4}",
"negate": true,
"match": "after",
},
"paths": paths,
"index": "logs-agent-default",
"processors": []map[string]interface{}{
Expand Down

0 comments on commit 1d67ba4

Please sign in to comment.