I'm using prom-client npm package to monitor my app. I've read here that "All metrics can take a labelNames property in the configuration object. All label names that the metric support needs to be declared here. (in the object given to the constructor)". I've to design a programmable interface that lets you define what labels do you want see in your time series.
For example you want sameMetric{label1=value1}
and sameMetric{label2=value2}
. Same metric but the time series have different labels
The only possible solution I can think of is that i must predeclare every single possible label name, but that's not the best solution because there's a plenty of them (session properties).
So if you know a better solution, let me know. Thanks