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

Stats Pusher to allow the same metric with different labels #20

Closed
anjackson opened this issue Nov 11, 2020 · 1 comment
Closed

Stats Pusher to allow the same metric with different labels #20

anjackson opened this issue Nov 11, 2020 · 1 comment

Comments

@anjackson
Copy link
Contributor

It's often handy to use the same metric with different labels, as it makes breakdown analysis easier. I wanted to do something like this:

trackdb_numFound = #######
trackdb_numFound{label='warcs'} = #####
trackdb_numFound{label='cdx'} = ####

i.e. use the label to count sub-sets of the total number of files found in TrackDB. However, because the metric name (trackdb_numFound) is constructed from the JSON dictionary keys, and we only have one metric definition per key, we can only use each metric name once. The meant to get it to work I had to use:

trackdb_numFound = ######
trackdb_numFound_warcs = #####
trackdb_numFound_cdx = ####

Which is not so easy to use.

@anjackson
Copy link
Contributor Author

This was implemented!

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

No branches or pull requests

1 participant