mirror of
https://github.com/tailscale/tailscale.git
synced 2024-11-25 19:15:34 +00:00
b615a1d4db
NewMultiLabelMap does not return an error so it's easy for someone to pass an incorrect/unsupported metric type and serve invalid metrics to Prometheus. This would read as `metrics.Counter` and `metrics.Gauge` when used, which seems readable enough; but if you think bare strings are better, an alternative to this approach might be to verify string value in `NewMultiLabelMap` and panic? Updates tailscale/corp#22075 Signed-off-by: Anton Tolchanov <anton@tailscale.com> |
||
---|---|---|
.. | ||
fds_linux.go | ||
fds_notlinux.go | ||
metrics_test.go | ||
metrics.go | ||
multilabelmap_test.go | ||
multilabelmap.go |