I mean, what if we consider a metricId also opaque, and we know that
in P8S
is a combination of <metric_name><labels>, at the end of the day, is a
string and it is unique.
I ask this, because if we expose the details, it will be tempted to start
manipulating IDs in other layers, and perhaps that will create technical
debt.
Just thinking off the top of my head, Prometheus's "family{labels}" ID is
not to be considered opaque. It is important, I think, that clients understand these
because it is how you query in Prometheus.
For example, to get a group (aggregate) metric value, you could query on just a subset of
labels thus aggregating over the labels you did not specify.
For example, if there is:
http_requests_time{method="POST", app="my.war"} = 1.0
http_requests_time{method="POST", app="another.war"} = 1.2
http_requests_time{method="GET", app="my.war"} = 0.5
http_requests_time{method="GET", app="another.war"} = 0.6
A client (MiQ UI?) can aggregate the GET request times across all apps by
knowing it only queries with the method label, like "average(
http_requests_time{method="GET"} )"
So therefore P metric IDs (family+labels) are not opaque - clients need to understand them
a bit.