mirror of
https://github.com/prometheus/prometheus.git
synced 2025-02-21 03:16:00 -08:00
Remove label from prometheus_target_skipped_scrapes_total (#2289)
This avoids it not being intialised, and breaking out by interval wasn't partiuclarly useful. Fixes #2269
This commit is contained in:
parent
f3f798fbcf
commit
f421ce0636
|
@ -47,12 +47,11 @@ var (
|
||||||
},
|
},
|
||||||
[]string{"interval"},
|
[]string{"interval"},
|
||||||
)
|
)
|
||||||
targetSkippedScrapes = prometheus.NewCounterVec(
|
targetSkippedScrapes = prometheus.NewCounter(
|
||||||
prometheus.CounterOpts{
|
prometheus.CounterOpts{
|
||||||
Name: "prometheus_target_skipped_scrapes_total",
|
Name: "prometheus_target_skipped_scrapes_total",
|
||||||
Help: "Total number of scrapes that were skipped because the metric storage was throttled.",
|
Help: "Total number of scrapes that were skipped because the metric storage was throttled.",
|
||||||
},
|
},
|
||||||
[]string{"interval"},
|
|
||||||
)
|
)
|
||||||
targetReloadIntervalLength = prometheus.NewSummaryVec(
|
targetReloadIntervalLength = prometheus.NewSummaryVec(
|
||||||
prometheus.SummaryOpts{
|
prometheus.SummaryOpts{
|
||||||
|
@ -430,7 +429,7 @@ func (sl *scrapeLoop) run(interval, timeout time.Duration, errc chan<- error) {
|
||||||
sl.report(start, time.Since(start), len(samples), err)
|
sl.report(start, time.Since(start), len(samples), err)
|
||||||
last = start
|
last = start
|
||||||
} else {
|
} else {
|
||||||
targetSkippedScrapes.WithLabelValues(interval.String()).Inc()
|
targetSkippedScrapes.Inc()
|
||||||
}
|
}
|
||||||
|
|
||||||
select {
|
select {
|
||||||
|
|
Loading…
Reference in a new issue