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 Path Fixes #1079

Merged
merged 8 commits into from
Oct 27, 2021
Merged

Query Path Fixes #1079

merged 8 commits into from
Oct 27, 2021

Conversation

joe-elliott
Copy link
Member

@joe-elliott joe-elliott commented Oct 26, 2021

What this PR does:
Fixes two issues in the query path:

  • Correctly counts failed blocks from 404ing queriers.
  • Fixes the hedged request metric that was incorrectly accumulating the counter.

The more I work on the query path the more it feels a little duct taped together. We should regroup and redesign this one day.

Checklist

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

Signed-off-by: Joe Elliott <[email protected]>
Signed-off-by: Joe Elliott <[email protected]>
@joe-elliott joe-elliott marked this pull request as draft October 26, 2021 18:06
Signed-off-by: Joe Elliott <[email protected]>
@joe-elliott joe-elliott marked this pull request as ready for review October 27, 2021 13:48
@@ -27,7 +27,7 @@ func PublishHedgedMetrics(s *hedgedhttp.Stats) {
ticker := time.NewTicker(hedgedMetricsPublishDuration)
go func() {
for range ticker.C {
hedgedRequestsMetrics.Add(float64(s.Snapshot().RequestedRoundTrips))
hedgedRequestsMetrics.Set(float64(s.Snapshot().RequestedRoundTrips))
Copy link
Member Author

Choose a reason for hiding this comment

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

counters don't allow you to set them directly. is there a better way to do this?

Signed-off-by: Joe Elliott <[email protected]>
Signed-off-by: Joe Elliott <[email protected]>
Signed-off-by: Joe Elliott <[email protected]>
@joe-elliott joe-elliott merged commit 5124375 into grafana:main Oct 27, 2021
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.

2 participants