PROM-0097: PromQL Metadata querying / promotion. - #97
roidelapluie wants to merge 3 commits into
Conversation
Signed-off-by: Julien Pivotto <291750+roidelapluie@users.noreply.github.com>
Signed-off-by: Julien Pivotto <291750+roidelapluie@users.noreply.github.com>
|
|
||
| 4. Native metadata can optionally be promoted to labels with the `as` keyword. | ||
|
|
||
| `foo{resource[power.status] as power_status}` `foo{namespace["super+name"] as "supername"}` |
There was a problem hiding this comment.
So what are the keywords allowed here? resource namespace? What else?
There was a problem hiding this comment.
This proposal is agnostic of the keywords. The keywords are actual namespaces of metadata and should be defined in a broader metadata design doc like the ones that exist. I can think of resource for OTLP: resource, k8s, host, service...
There was a problem hiding this comment.
Thanks. I am missing an exact definition of "namespace" or "scope", especially how it would be reflected in Prometheus world. Also if we expect UTF-8 in those (:
Maybe it's out of scope, but then how we could understand limitations of <prefix>[<suffix>] syntax?
If we mean here OTel entity namespaces and let's take process.executable)
Then should I go for
cpu_info{process["executable.name"]="docker" as exec}
or
cpu_info{"process.executable"[name]="docker" as exec}
..and if this "namespacing" is required, why not cpu_info{["process.executable.name"]="docker" as exec}
Then can we guarentee some namespace is always there for metadata?
There was a problem hiding this comment.
I believe we can have better and will do a second proposal later.
|
Closing in favour of #99 |
This proposal was writting by hand. Grammar fixed by AI.
I asked AI 5 examples queries: