You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a use case where I'm trying to produce a configuration validation error for a receiver that intends to reference a particular metric name. In particular the scenario is if a particular technology is disabled but a particular metric that requires that subsystem is enabled, I want to produce an error like:
Metric metric.name requires subsystem to be enabled
What would be great would be to reference the name directly from the mdatagen generated package, as putting the metric name directly in the error isn't future-proof against the metric name changing.
I have no particular preference for what this API looks like, provided it allows me to access any metric or resource attribute names. If there already is a way to do this and I've missed it, I will close this issue.
The text was updated successfully, but these errors were encountered:
Component(s)
cmd/mdatagen
Describe the issue you're reporting
I have a use case where I'm trying to produce a configuration validation error for a receiver that intends to reference a particular metric name. In particular the scenario is if a particular technology is disabled but a particular metric that requires that subsystem is enabled, I want to produce an error like:
Metric metric.name requires subsystem to be enabled
What would be great would be to reference the name directly from the
mdatagen
generated package, as putting the metric name directly in the error isn't future-proof against the metric name changing.I have no particular preference for what this API looks like, provided it allows me to access any metric or resource attribute names. If there already is a way to do this and I've missed it, I will close this issue.
The text was updated successfully, but these errors were encountered: