I have a use-case where I want to log a metric from App A. The label values (message categories) are pre-defined in our system, but App A is designed to be flexible so as far as categories are concerned as it is used in other systems.
So App A doesn't know all the values the label can take. I am not sure if Prometheus allows labels to change dynamically but client library examples appear to show I should define all my labels at start-up, though I may be misunderstanding this!
What I probably would like is that the first time each category is seen in App A, a label-value is created (we're in C++ so probably a simple std::map implementation) but I don't know how practical this is - surely other people have come across this kind of situation, can anyone offer some advice?
The other problem is that App A only knows categories by numeric ID, as ID-name mapping is system-specific. But I think that is quite easily addressed in my YAML file?
Many thanks,
John.