MCPcopy Index your code
hub / github.com/cortexproject/cortex / HasMaxRuleGroupsLimit

Method HasMaxRuleGroupsLimit

pkg/ruler/ruler.go:1545–1548  ·  view source on GitHub ↗

HasMaxRuleGroupsLimit check if RulerMaxRuleGroupsPerTenant limit is set for the userID.

(userID string)

Source from the content-addressed store, hash-verified

1543
1544// HasMaxRuleGroupsLimit check if RulerMaxRuleGroupsPerTenant limit is set for the userID.
1545func (r *Ruler) HasMaxRuleGroupsLimit(userID string) bool {
1546 limit := r.limits.RulerMaxRuleGroupsPerTenant(userID)
1547 return limit > 0
1548}
1549
1550// AssertMaxRuleGroups limit has not been reached compared to the current
1551// number of total rule groups in input and returns an error if so.

Callers 1

CreateRuleGroupMethod · 0.80

Calls 1

Tested by

no test coverage detected