mirror of
https://github.com/prometheus/prometheus.git
synced 2024-12-27 14:39:40 -08:00
scraping errors will show in the log when debug mode is enabled (#3135)
Signed-off-by: Krasi Georgiev <krasi.root@gmail.com>
This commit is contained in:
parent
c70379e1c7
commit
153cb0cbe3
|
@ -637,8 +637,11 @@ mainLoop:
|
||||||
var b []byte
|
var b []byte
|
||||||
if scrapeErr == nil {
|
if scrapeErr == nil {
|
||||||
b = buf.Bytes()
|
b = buf.Bytes()
|
||||||
} else if errc != nil {
|
} else {
|
||||||
errc <- scrapeErr
|
sl.l.With("err", scrapeErr.Error()).Debug("scrape failed")
|
||||||
|
if errc != nil {
|
||||||
|
errc <- scrapeErr
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// A failed scrape is the same as an empty scrape,
|
// A failed scrape is the same as an empty scrape,
|
||||||
|
|
Loading…
Reference in a new issue