Add `Unregister` method for metrics
Opened this issue · 3 comments
hagen1778 commented
See VictoriaMetrics/VictoriaMetrics#2127 (comment) as example.
aierui commented
Hi @hagen1778
What should be the best practice for removing a metric that contains multiple tags?
eg.
metrics_name1{tag1="v1",tag2="v2"} 1
metrics_name1{tag1="v3",tag2="v4"} 1
metrics_name1{tag1="v5",tag2="v6"} 1
metrics_name1{tag1="v7",tag2="v8"} 1
....
hagen1778 commented
Hi @aierui!
So far while this FR isn't completed, the best way to unregister a specific metric would be the following:
metrics.UnregisterMetric('metrics_name1{tag1="v1",tag2="v2"}')
aierui commented
Thank you for your reply.