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

[query] Add parse expression functionality #2278

Merged
merged 4 commits into from
Apr 23, 2020
Merged

Conversation

arnikola
Copy link
Collaborator

@arnikola arnikola commented Apr 22, 2020

Adds parse functionality to expose the raw fetches within a query.

Copy link
Collaborator

@robskillington robskillington left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (but also not required, if you write before status code sent it will default to 200=ok)

@arnikola arnikola force-pushed the arnikola/set-header branch from 0884506 to 91aa625 Compare April 23, 2020 03:29
@arnikola arnikola changed the title [query] Correctly write success header [query] Add parse expression functionality Apr 23, 2020
var req *prompb.ReadRequest
var rErr *xhttp.ParseError
switch {
case r.Method == http.MethodGet && strings.TrimSpace(r.FormValue("expr")) != "":
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have to change this to "query" or what have you to make it compatible with the PromQL query client library methods?

@arnikola arnikola merged commit 4ef0a70 into master Apr 23, 2020
@arnikola arnikola deleted the arnikola/set-header branch April 23, 2020 17:26
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 this pull request may close these issues.

3 participants