Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use of dimensions produces empty metric #80

Open
freef4ll opened this issue Nov 22, 2022 · 0 comments · May be fixed by #81
Open

Use of dimensions produces empty metric #80

freef4ll opened this issue Nov 22, 2022 · 0 comments · May be fixed by #81
Assignees
Milestone

Comments

@freef4ll
Copy link

If one creates a Gauge or a Counter with dimensions, an exported value actually contains 2 metrics, this when visualized in Grafana will also result in 2 graphs, one which displays the initial 0 value and one with the actual metric:

let g = Gauge(label: "test_gauge", dimensions: [("abc", "123")])
g.record(10)

This will produce the output of:

# TYPE test counter
test_gauge 0
test_gauge{abc="123"} 10

The issue is slightly touched on in #77

Potential fix/workaround might be master...ordo-one:SwiftPrometheus:gauge_label

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants