Skip to content

Commit

Permalink
Add ruler limits
Browse files Browse the repository at this point in the history
Sets default presets for for all the 'users' when it comes to ruler
limits.
  • Loading branch information
gotjosh committed Nov 9, 2020
1 parent 0bf59b4 commit e0a78db
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## master / unreleased

* [CHANGE] Add default present for ruler limits on all 'user' types.
* [CHANGE] Add the default preset 'extra_small_user' and reference it in the CLI flags. This will raise the limits of the 'small_user' preset to the defaults for `ingester.max-samples-per-query` and `ingester.max-series-per-query`. #200
* [ENHANCEMENT] Add the Ruler to the read resources dashboard #205
* [ENHANCEMENT] Read dashboards now use `cortex_querier_request_duration_seconds` metrics to allow for accurate dashboards when deploying Cortex as a single-binary. #199
Expand Down
23 changes: 23 additions & 0 deletions cortex/config.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,10 @@

ingestion_rate: 10000,
ingestion_burst_size: 200000,

// 300 rules
max_rules_per_rule_group: 15,
max_rule_groups_per_tenant: 20,
},

small_user:: {
Expand All @@ -308,6 +312,10 @@

ingestion_rate: 100000,
ingestion_burst_size: 1000000,

// 450 rules
max_rules_per_rule_group: 15,
max_rule_groups_per_tenant: 30,
},

medium_user:: {
Expand All @@ -322,6 +330,10 @@

ingestion_rate: 350000, // 350K
ingestion_burst_size: 3500000, // 3.5M

// 600 rules
max_rules_per_rule_group: 15,
max_rule_groups_per_tenant: 40,
},

big_user:: {
Expand All @@ -336,6 +348,10 @@

ingestion_rate: 700000, // 700K
ingestion_burst_size: 7000000, // 7M

// 750 rules
max_rules_per_rule_group: 15,
max_rule_groups_per_tenant: 50,
},

super_user:: {
Expand All @@ -350,6 +366,10 @@

ingestion_rate: 1500000, // 1.5M
ingestion_burst_size: 15000000, // 15M

// 900 rules
max_rules_per_rule_group: 15,
max_rule_groups_per_tenant: 60,
},

// This user class has limits increased by +50% compared to the previous one.
Expand All @@ -365,6 +385,9 @@

ingestion_rate: 2250000, // 2.25M
ingestion_burst_size: 22500000, // 22.5M

max_rules_per_rule_group: 15,
max_rule_groups_per_tenant: 70,
},
},

Expand Down
4 changes: 4 additions & 0 deletions cortex/ruler.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@
// Ring Configs
'ruler.enable-sharding': true,
'ruler.ring.consul.hostname': 'consul.%s.svc.cluster.local:8500' % $._config.namespace,

// Limits
'ruler.max-rules-per-rule-group': $._config.limits.max_rules_per_rule_group,
'ruler.max-rule-groups-per-tenant': $._config.limits.max_rule_groups_per_tenant,
},

ruler_container::
Expand Down

0 comments on commit e0a78db

Please sign in to comment.