(ts prompb.TimeSeries)
| 207 | } |
| 208 | |
| 209 | func getNameAndAttributes(ts prompb.TimeSeries) (string, map[string]any) { |
| 210 | var metricName string |
| 211 | attributes := make(map[string]any) |
| 212 | for _, label := range ts.Labels { |
| 213 | if label.Name == model.MetricNameLabel { |
| 214 | metricName = label.Value |
| 215 | } else { |
| 216 | attributes[label.Name] = label.Value |
| 217 | } |
| 218 | } |
| 219 | return metricName, attributes |
| 220 | } |
| 221 | |
| 222 | func createDataPointsGauge(newMetric pmetric.Metric, attributes map[string]any, samples []prompb.Sample) { |
| 223 | newMetric.SetEmptyGauge() |
no outgoing calls
no test coverage detected