filterAcceptableAgentLabels handles a slightly messy situation whereby `prometheus-aggregate-agent-stats-by` can control on which labels agent stats are aggregated, but for these specific metrics in this file there is no `template` label value, and therefore we have to exclude it from the list of ac
(labels []string)
| 678 | // which labels agent stats are aggregated, but for these specific metrics in this file there is no `template` label value, |
| 679 | // and therefore we have to exclude it from the list of acceptable labels. |
| 680 | func filterAcceptableAgentLabels(labels []string) []string { |
| 681 | out := make([]string, 0, len(labels)) |
| 682 | for _, label := range labels { |
| 683 | if label != agentmetrics.LabelTemplateName { |
| 684 | out = append(out, label) |
| 685 | } |
| 686 | } |
| 687 | |
| 688 | return out |
| 689 | } |
no outgoing calls