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

QueryFrontend: fixing bug on cortex cache for range query when using dynamic sharding #5688

Conversation

pedro-stanaka
Copy link
Contributor

@pedro-stanaka pedro-stanaka commented Sep 14, 2022

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

Changes

In #5617 I introduced new parameters for horizontal sharding, but I did not keep track of the usage of the query-range.split-interval parameter in other places. It was being used in QFE caching mechanism to generate cache keys and by using the new parameters a division by zero error would occur, this PR solves this problem.

Verification

Created e2e test to reproduce the error I saw on my staging environment.

Signed-off-by: Pedro Tanaka <[email protected]>
Signed-off-by: Pedro Tanaka <[email protected]>
Signed-off-by: Pedro Tanaka <[email protected]>
CHANGELOG.md Outdated
@@ -11,6 +11,7 @@ We use *breaking :warning:* to mark changes that are not backward compatible (re
## Unreleased

### Fixed
- [#5688](https://github.com/thanos-io/thanos/pull/5688) Query Frontend: Fix bug with dynamic horizontal sharding parameters and cache key generator.
Copy link
Contributor

Choose a reason for hiding this comment

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

Since the feature is not yet released, I don't think we need a changelog entry.

Copy link
Contributor

@fpetkovski fpetkovski left a comment

Choose a reason for hiding this comment

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

Thanks for the quick fix, just one minor comment from my side.

Signed-off-by: Pedro Tanaka <[email protected]>
@pedro-stanaka
Copy link
Contributor Author

Thanks for the quick fix, just one minor comment from my side.

Done

Copy link
Contributor

@fpetkovski fpetkovski left a comment

Choose a reason for hiding this comment

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

👍

@yeya24 yeya24 enabled auto-merge (squash) September 14, 2022 18:30
@yeya24 yeya24 disabled auto-merge September 14, 2022 18:31
Copy link
Contributor

@yeya24 yeya24 left a comment

Choose a reason for hiding this comment

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

Thanks!

@yeya24 yeya24 merged commit 0d8562b into thanos-io:main Sep 14, 2022
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.

3 participants