Ensure remote write v2 headers cannot be returned on v1 requests#1927
Merged
bwplotka merged 1 commit intoprometheus:mainfrom Dec 12, 2025
Merged
Conversation
Signed-off-by: Kyle Eckhart <kgeckhart@users.noreply.github.com>
kgeckhart
added a commit
to grafana/alloy
that referenced
this pull request
Feb 12, 2026
### Brief description of Pull Request Bump to prometheus patch release to pull in the fix for prometheus/prometheus#17659 which would impact `prometheus.receive_http` which uses the upstream `remote.NewWriteHandler` which was impacted by prometheus/client_golang#1927. ### Issue(s) fixed by this Pull Request Resolves: #5471 ### Notes to the Reviewer I didn't add a test because it's a rather low level implementation details about returning response stats vs not returning response stats. I'm open to adding one though.
grafana-alloybot bot
pushed a commit
to grafana/alloy
that referenced
this pull request
Feb 12, 2026
### Brief description of Pull Request Bump to prometheus patch release to pull in the fix for prometheus/prometheus#17659 which would impact `prometheus.receive_http` which uses the upstream `remote.NewWriteHandler` which was impacted by prometheus/client_golang#1927. ### Issue(s) fixed by this Pull Request Resolves: #5471 ### Notes to the Reviewer I didn't add a test because it's a rather low level implementation details about returning response stats vs not returning response stats. I'm open to adding one though. (cherry picked from commit b7a1d05)
kgeckhart
added a commit
to grafana/alloy
that referenced
this pull request
Feb 12, 2026
…ort] (#5516) ## Backport of #5505 This PR backports #5505 to release/v1.13. ### Original PR Author @kgeckhart ### Description ### Brief description of Pull Request Bump to prometheus patch release to pull in the fix for prometheus/prometheus#17659 which would impact `prometheus.receive_http` which uses the upstream `remote.NewWriteHandler` which was impacted by prometheus/client_golang#1927. ### Issue(s) fixed by this Pull Request Resolves: #5471 ### Notes to the Reviewer I didn't add a test because it's a rather low level implementation details about returning response stats vs not returning response stats. I'm open to adding one though. --- *This backport was created automatically.* Co-authored-by: Kyle Eckhart <kgeckhart@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR prevents the remote_api WriteHandler from adding Remote Write v2 response headers when handling a v1 payload. This ensures a sender, like prometheus itself, cannot misinterpret the stats which are liable to always be zero for RWv1.
Related to: prometheus/prometheus#17659