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

Docs: add -frontend.enabled-ruler-query-stats to docs #6530

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions docs/guides/rule-evaluations-via-query-frontend.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,18 @@ In addition, you can configure gRPC client (Ruler -> Query Frontend) config, ple
You can configure the query response format via `-ruler.query-response-format`. It is used to retrieve query results from the Query Frontend.
The supported values are `protobuf` and `json`. We recommend using `protobuf`(default) because the retrieved query results containing native histograms are only supported on `protobuf`.

## How to track query stat log and metric
When the `-ruler.frontend-address` is configured, the values of query stats for rule evaluation logs and metrics are all `0` in the Ruler.
You can look at the logs at the Query Frontend via enabling `-frontend.enabled-ruler-query-stats` (disabled by default).

Also, there are alternative metrics; you can see right-side metrics instead:
```
`cortex_ruler_query_seconds_total` -> `cortex_query_seconds_total{source="ruler"}`
`cortex_ruler_fetched_series_total` -> `cortex_query_fetched_series_total{source="ruler"}`
`cortex_ruler_samples_total` -> `cortex_query_samples_total{source="ruler"}`
`cortex_ruler_fetched_chunks_bytes_total` -> `cortex_query_fetched_chunks_bytes_total{source="ruler"}`
`cortex_ruler_fetched_data_bytes_total` -> `cortex_query_fetched_data_bytes_total{source="ruler"}`
```

## Pros and Cons
If this feature is enabled, the query execute path is as follows:
Expand Down
Loading