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

pkg/store: Expose metric about empty stream responses in proxy store #2030

Merged
merged 1 commit into from
Jan 23, 2020

Conversation

brancz
Copy link
Member

@brancz brancz commented Jan 22, 2020

  • I added CHANGELOG entry for this change.
  • Change is not relevant to the end user.

Changes

This adds a metric to track how often we do requests that end up in empty responses. Related to #1611.

Verification

Did queries that stores didn't have data for, and verified that indeed the /metrics endpoint reflects this.

@bwplotka @squat @GiedriusS

@@ -348,6 +374,12 @@ func startStreamSeriesSet(
defer wg.Done()
defer close(s.recvCh)

i := 0
Copy link
Member

@GiedriusS GiedriusS Jan 22, 2020

Choose a reason for hiding this comment

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

I feel like a more descriptive name like numResponses would be better. I am way too used to seeing i as a placeholder variable in for-loops for the index 😄 Here we do an infinite loop so it probably doesn't fit as well.

Copy link
Member Author

Choose a reason for hiding this comment

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

agreed

@brancz brancz force-pushed the empty-stream-response-metric branch from d572ae8 to 10e2f6e Compare January 22, 2020 19:03
@GiedriusS
Copy link
Member

There was an attempt to add a similar thing here as well: #1789

Copy link
Member

@bwplotka bwplotka left a comment

Choose a reason for hiding this comment

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

We have a build error, but otherwise it looks good (:

Good start: observe how often we hit this situation!

Giedrius, not really connected to other issues, it's not about slow stores but rather stores that were asked for data that they don't have.

@brancz brancz force-pushed the empty-stream-response-metric branch from 10e2f6e to 5a8026e Compare January 23, 2020 11:53
Signed-off-by: Frederic Branczyk <fbranczyk@gmail.com>
@brancz brancz force-pushed the empty-stream-response-metric branch from 5a8026e to 63c2d53 Compare January 23, 2020 11:54
Copy link
Member

@squat squat left a comment

Choose a reason for hiding this comment

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

lgtm

@brancz brancz merged commit 860bbaf into thanos-io:master Jan 23, 2020
@brancz brancz deleted the empty-stream-response-metric branch January 23, 2020 12:21
@GiedriusS
Copy link
Member

Giedrius, not really connected to other issues, it's not about slow stores but rather stores that were asked for data that they don't have.

Hence the word 'similar' 😄

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.

5 participants