Fix infinit suffix add to counter metrics#3491
Conversation
|
There is critical bug in Prometheus exporter, counters are growing indefinitely by adding _total to the end of the metric. |
MrAlias
left a comment
There was a problem hiding this comment.
This will move our implementation out of compliance with the specification: https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/compatibility/prometheus_and_openmetrics.md#sums
Monotonic Sum metric points MUST have _total added as a suffix to the metric name.
If someone already named their metric with a suffix of _total an additional _total suffix must be added still.
|
Thanks @MrAlias , but where should we check this infinit loop. The problem is with each new variableLabel change we get another _total added to the counter name. HELP qlub_pos_requests_ratio_totalTYPE qlub_pos_requests_ratio_total counterqlub_pos_requests_ratio_total{code="200",country_code="ae",method="get_order",vendor="dummy"} 6 HELP qlub_pos_requests_ratio_total_totalTYPE qlub_pos_requests_ratio_total_total counterqlub_pos_requests_ratio_total_total{code="200",country_code="ae",method="get_table",vendor="dummy"} 1 |
|
ok i realized this bug is in current release tag v0.33.0 and is fixed in main branch. I close this PR. It should be fixed in next release. |
|
BTW, i think it is critical bug, why not release a hotfix v0.33.1 for it ? @MrAlias |
|
For the next reader, the fix went in here: #3369 |
No description provided.