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

[Issue-8106] Fix tenant hashring glob with multiple tenant match patterns #8107

Merged
merged 1 commit into from
Feb 20, 2025

Conversation

jnyi
Copy link
Contributor

@jnyi jnyi commented Feb 14, 2025

see #8106

Without this change, unit test "glob hashring multiple matches" will fail
Screenshot 2025-02-14 at 12 53 53 PM

it passes after the fix

Screenshot 2025-02-14 at 12 54 06 PM
  • I added CHANGELOG entry for this change.
  • Change is not relevant to the end user.

Changes

Verification

Signed-off-by: Yi Jin <yi.jin@databricks.com>
if err != nil {
return false, fmt.Errorf("error matching tenant pattern %s (tenant %s): %w", tenantPattern, tenant, err)
}
if matches {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

should short circuit when a match is found, old code will continue and ignore previous matched pattern

@GiedriusS GiedriusS merged commit 426b2f1 into thanos-io:main Feb 20, 2025
22 checks passed
neevnuv pushed a commit to neevnuv/thanos that referenced this pull request Feb 20, 2025
…hanos-io#8107)

Signed-off-by: Yi Jin <yi.jin@databricks.com>
Signed-off-by: neevnuv <neevnuv@gmail.com>
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.

2 participants