-
Notifications
You must be signed in to change notification settings - Fork 374
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Set default labels on a single metric #598
Labels
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I would like to propose an option to be added to each metric type, which would allow specifying default label values for that metric only. Those labels would then be applied to each metric value (unless the value is overridden when recorded, similar to how default labels already work at the client level in
prom-client
).It would look something like this:
If this is a valid use case / not already possible, I would love to contribute.
More use case details:
My team uses prom-client to expose metrics which are scraped by prometheus and ultimately pushed to newrelic via a prometheus remote write integration.
We have an issue occasionally where if a metric is created that does not follow the naming convention expected by newrelic, newrelic interprets the metric as an inappropriate type (most often, counters are interpreted as gauges). I'd like to use this API to add the
newrelic_metric_type
label in a universal way to prevent this.The text was updated successfully, but these errors were encountered: