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

ruler: support /config/api/v1/rules/{namespace}/{groupName} for local storage #6632

Closed
dimitarvdimitrov opened this issue Nov 13, 2023 · 0 comments · Fixed by #7248
Closed
Labels

Comments

@dimitarvdimitrov
Copy link
Contributor

dimitarvdimitrov commented Nov 13, 2023

The endpoint /config/api/v1/rules/{namespace}/{groupName} isn't supported for local rules storage.

// GetRuleGroup implements RuleStore
func (l *Client) GetRuleGroup(_ context.Context, _, _, _ string) (*rulespb.RuleGroupDesc, error) {
return nil, errors.New("GetRuleGroup unsupported in rule local store")
}

Since this is a read-only endpoint the ruler should be able to support it. This is how the ruler accesses all the rule groups for a namespace for a user. The logic can be reused

func (l *Client) loadAllRulesGroupsForUser(ctx context.Context, userID string) (rulespb.RuleGroupList, error) {

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 a pull request may close this issue.

1 participant