mirror of
https://github.com/prometheus/prometheus.git
synced 2026-05-05 04:16:15 +02:00
[PERF] Scraping: skip an unnecessary step when there are relabel rules
Before it would do Builder->Labels->Builder, now we skip the conversions. Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
This commit is contained in:
parent
b0649e08c4
commit
77ba5c5fbd
@ -716,13 +716,9 @@ func mutateSampleLabels(lset labels.Labels, target *Target, honor bool, rc []*re
|
||||
}
|
||||
}
|
||||
|
||||
res := lb.Labels()
|
||||
relabel.ProcessBuilder(lb, rc...)
|
||||
|
||||
if len(rc) > 0 {
|
||||
res, _ = relabel.Process(res, rc...)
|
||||
}
|
||||
|
||||
return res
|
||||
return lb.Labels()
|
||||
}
|
||||
|
||||
func resolveConflictingExposedLabels(lb *labels.Builder, conflictingExposedLabels []labels.Label) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user