MCPcopy Create free account
hub / github.com/netdata/netdata / removeLabel

Function removeLabel

src/go/pkg/prometheus/parse.go:407–414  ·  view source on GitHub ↗
(lbs labels.Labels, name string)

Source from the content-addressed store, hash-verified

405}
406
407func removeLabel(lbs labels.Labels, name string) (labels.Labels, string, bool) {
408 for i, v := range lbs {
409 if v.Name == name {
410 return append(lbs[:i], lbs[i+1:]...), v.Value, true
411 }
412 }
413 return lbs, "", false
414}
415
416func metricNameValue(lbs labels.Labels) (string, bool) {
417 for _, v := range lbs {

Callers 7

setQuantileMethod · 0.85
setBucketMethod · 0.85
addGaugeMethod · 0.85
addCounterMethod · 0.85
addUnknownMethod · 0.85
addSummaryMethod · 0.85
addHistogramMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…