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

Querier: Unset Host Header if DownstreamUrl is configured #2880

Merged
merged 3 commits into from Jul 15, 2020

Conversation

tonobo
Copy link
Contributor

@tonobo tonobo commented Jul 15, 2020

What this PR does:

This change is necessary to correctly pass the Host Header to backend
service. The Host Header will be set by stdlib, so flushing them should
do the trick.

Which issue(s) this PR fixes:
Fixes #2875

Checklist

  • Tests updated
  • Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

This change is necessary to correctly pass the Host Header to backend
service. The Host Header will be set by stdlib, so flushing them should
do the trick.

Signed-off-by: Tim Foerster <tim.foerster@hetzner.com>
Signed-off-by: Marco Pracucci <marco@pracucci.com>
Copy link
Contributor

@pracucci pracucci left a comment

Choose a reason for hiding this comment

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

Thanks, LGTM! ❤️

Hope you don't mind I've pushed a unit test for it.

CHANGELOG.md Outdated Show resolved Hide resolved
Signed-off-by: Marco Pracucci <marco@pracucci.com>
Copy link
Contributor

@pstibrany pstibrany left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for the contribution!

@tonobo
Copy link
Contributor Author

tonobo commented Jul 15, 2020

Cool! Thanks!

@pracucci pracucci merged commit bf3cbdc into cortexproject:master Jul 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

query-frontend: Different HTTP Headers on /api/v1/query and /api/v1/query_range calls
3 participants