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

Push does not work with blank grouping key values #652

Closed
BrandonY opened this issue May 15, 2023 · 1 comment
Closed

Push does not work with blank grouping key values #652

BrandonY opened this issue May 15, 2023 · 1 comment

Comments

@BrandonY
Copy link

Pushgateway encodes grouping label keys and values as URL path segments. Those values may be blank, but URL path segments may not be blank. To get around this, pushgateway requires that empty values be encoded as the character '='.

See https://github.com/prometheus/pushgateway#url for details.

This project doesn't do this and leaves the value blank, so if you have a label with a name like "label1" and a blank value, you get a request path like this: /metrics/job/label1//label2/bla. That's not a valid request path, or worse, it is, but it's equivalent to /metrics/job/label1/label2/bla, which doesn't work.

gjasny added a commit that referenced this issue Dec 18, 2023
gjasny added a commit that referenced this issue Dec 19, 2023
gjasny added a commit that referenced this issue Dec 19, 2023
@gjasny gjasny closed this as completed in 3eca7c6 Dec 19, 2023
@gjasny
Copy link
Collaborator

gjasny commented Dec 19, 2023

Thanks for reporting and the initial PR.

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

Successfully merging a pull request may close this issue.

2 participants