Skip to content

Commit

Permalink
Add logging when monitoring cannot connect (elastic#6365)
Browse files Browse the repository at this point in the history
Currently when the monitoring can not connect to Elasticsearch no errors
is show in the log making this issue really hard to debug, this change
the behavior to send any error to the log.

Fixes: elastic#6327

(cherry picked from commit b4c92f8)
  • Loading branch information
ph committed Feb 13, 2018
1 parent 6018800 commit 640b434
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions libbeat/monitoring/report/elasticsearch/elasticsearch.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,8 @@ func (r *reporter) initLoop() {
if err == nil {
closing(client)
break
} else {
logp.Err("Monitoring could not connect to elasticsearch, failed with %v", err)
}

select {
Expand Down

0 comments on commit 640b434

Please sign in to comment.