Skip to content

Commit

Permalink
Mark query_ingesters_within and query_store_after as advanced
Browse files Browse the repository at this point in the history
Now that they have good defaults that match what we run in production,
they shouldn't need to be tuned by users in most cases.

Fixes #1924

Signed-off-by: Nick Pillitteri <nick.pillitteri@grafana.com>
  • Loading branch information
56quarters committed May 25, 2022
1 parent 679b9d6 commit 29cd538
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 14 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
- `-blocks-storage.bucket-store.ignore-blocks-within` now defaults to `10h` (previously `0`)
- `-querier.query-store-after` now defaults to `12h` (previously `0`)
- `-querier.shuffle-sharding-ingesters-lookback-period` now defaults to `13h` (previously `0`)
* [CHANGE] The following settings are now classified as advanced because the defaults should work for most users and tuning them requires in-depth knowledge of how the read path works: #TBD
- `-querier.query-ingesters-within`
- `-querier.query-store-after`
* [ENHANCEMENT] Store-gateway: Add the experimental ability to run requests in a dedicated OS thread pool. This feature can be configured using `-store-gateway.thread-pool-size` and is disabled by default. Replaces the ability to run index header operations in a dedicated thread pool. #1660 #1812
* [ENHANCEMENT] Improved error messages to make them easier to understand and referencing a unique global identifier that can be looked up in the runbooks. #1907 #1919
* [ENHANCEMENT] Memberlist KV: incoming messages are now processed on per-key goroutine. This may reduce loss of "maintanance" packets in busy memberlist installations, but use more CPU. New `memberlist_client_received_broadcasts_dropped_total` counter tracks number of dropped per-key messages. #1912
Expand Down
6 changes: 4 additions & 2 deletions cmd/mimir/config-descriptor.json
Original file line number Diff line number Diff line change
Expand Up @@ -1377,7 +1377,8 @@
"fieldValue": null,
"fieldDefaultValue": 46800000000000,
"fieldFlag": "querier.query-ingesters-within",
"fieldType": "duration"
"fieldType": "duration",
"fieldCategory": "advanced"
},
{
"kind": "field",
Expand All @@ -1387,7 +1388,8 @@
"fieldValue": null,
"fieldDefaultValue": 43200000000000,
"fieldFlag": "querier.query-store-after",
"fieldType": "duration"
"fieldType": "duration",
"fieldCategory": "advanced"
},
{
"kind": "field",
Expand Down
4 changes: 0 additions & 4 deletions cmd/mimir/help.txt.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -337,10 +337,6 @@ Usage of ./cmd/mimir/mimir:
Maximum number of split (by time) or partial (by shard) queries that will be scheduled in parallel by the query-frontend for a single input query. This limit is introduced to have a fairer query scheduling and avoid a single query over a large time range saturating all available queriers. (default 14)
-querier.max-samples int
Maximum number of samples a single query can load into memory. This config option should be set on query-frontend too when query sharding is enabled. (default 50000000)
-querier.query-ingesters-within duration
Maximum lookback beyond which queries are not sent to ingester. 0 means all queries are sent to ingester. (default 13h0m0s)
-querier.query-store-after duration
The time after which a metric should be queried from storage and not just ingesters. 0 means all queries are sent to store. If this option is enabled, the time range of the query sent to the store-gateway will be manipulated to ensure the query end is not more recent than 'now - query-store-after'. (default 12h0m0s)
-querier.scheduler-address string
Address of the query-scheduler component, in host:port format. Only one of -querier.frontend-address or -querier.scheduler-address can be set. If neither is set, queries are only received via HTTP endpoint.
-querier.timeout duration
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -791,15 +791,16 @@ The `querier` block configures the querier.
# CLI flag: -querier.batch-iterators
[batch_iterators: <boolean> | default = true]

# Maximum lookback beyond which queries are not sent to ingester. 0 means all
# queries are sent to ingester.
# (advanced) Maximum lookback beyond which queries are not sent to ingester. 0
# means all queries are sent to ingester.
# CLI flag: -querier.query-ingesters-within
[query_ingesters_within: <duration> | default = 13h]

# The time after which a metric should be queried from storage and not just
# ingesters. 0 means all queries are sent to store. If this option is enabled,
# the time range of the query sent to the store-gateway will be manipulated to
# ensure the query end is not more recent than 'now - query-store-after'.
# (advanced) The time after which a metric should be queried from storage and
# not just ingesters. 0 means all queries are sent to store. If this option is
# enabled, the time range of the query sent to the store-gateway will be
# manipulated to ensure the query end is not more recent than 'now -
# query-store-after'.
# CLI flag: -querier.query-store-after
[query_store_after: <duration> | default = 12h]

Expand Down
4 changes: 2 additions & 2 deletions pkg/querier/querier.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ import (
type Config struct {
Iterators bool `yaml:"iterators" category:"advanced"`
BatchIterators bool `yaml:"batch_iterators" category:"advanced"`
QueryIngestersWithin time.Duration `yaml:"query_ingesters_within"`
QueryIngestersWithin time.Duration `yaml:"query_ingesters_within" category:"advanced"`

// QueryStoreAfter the time after which queries should also be sent to the store and not just ingesters.
QueryStoreAfter time.Duration `yaml:"query_store_after"`
QueryStoreAfter time.Duration `yaml:"query_store_after" category:"advanced"`
MaxQueryIntoFuture time.Duration `yaml:"max_query_into_future" category:"advanced"`

StoreGatewayClient ClientConfig `yaml:"store_gateway_client"`
Expand Down

0 comments on commit 29cd538

Please sign in to comment.