HasMaxRuleGroupsLimit check if RulerMaxRuleGroupsPerTenant limit is set for the userID.
(userID string)
| 1543 | |
| 1544 | // HasMaxRuleGroupsLimit check if RulerMaxRuleGroupsPerTenant limit is set for the userID. |
| 1545 | func (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. |
no test coverage detected