mirror of
https://github.com/steinhobelgruen/netatmo-exporter.git
synced 2024-11-22 01:13:56 +00:00
Fix stale threshold
This commit is contained in:
parent
3d98195772
commit
b757b59f9f
|
@ -138,7 +138,7 @@ func (c *netatmoCollector) collectData(ch chan<- prometheus.Metric, device *neta
|
||||||
|
|
||||||
date := time.Unix(*data.LastMeasure, 0)
|
date := time.Unix(*data.LastMeasure, 0)
|
||||||
if time.Since(date) > c.staleThreshold {
|
if time.Since(date) > c.staleThreshold {
|
||||||
c.log.Warnf("Data is stale: %s > %s", time.Since(date), c.staleThreshold)
|
c.log.Warnf("Data is stale for %s: %s > %s", moduleName, time.Since(date), c.staleThreshold)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue