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

Series API should support match[] encoding #1842

Closed
owen-d opened this issue Mar 23, 2020 · 0 comments · Fixed by #1875
Closed

Series API should support match[] encoding #1842

owen-d opened this issue Mar 23, 2020 · 0 comments · Fixed by #1875
Labels
keepalive An issue or PR that will be kept alive and never marked as stale.

Comments

@owen-d
Copy link
Member

owen-d commented Mar 23, 2020

Currently Prometheus uses match[] to encode multiple values, whereas Loki uses multiple match clauses in a querystring such as match=<>&match=<>. This stems from there being multiple ways to encode a list of values for the same key in a querystring. Our current approach works well with i.e. curl, but does not work with promtool.

Therefore, we should handle both encoding types.

Reference:

xs := r.Form["match"]

https://github.com/prometheus/client_golang/blob/aa9238db679fc02bf22cf4f2c27a980edcb5ada0/api/prometheus/v1/api.go#L713

@yeya24 Thanks for the digging here.

@owen-d owen-d added the keepalive An issue or PR that will be kept alive and never marked as stale. label Mar 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
keepalive An issue or PR that will be kept alive and never marked as stale.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant