diff --git a/cortex-mixin/dashboards/dashboard-utils.libsonnet b/cortex-mixin/dashboards/dashboard-utils.libsonnet index 57ae82b3..ddff873b 100644 --- a/cortex-mixin/dashboards/dashboard-utils.libsonnet +++ b/cortex-mixin/dashboards/dashboard-utils.libsonnet @@ -30,7 +30,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; else self, addRows(rows):: - addRowsIf(true, rows), + self.addRowsIf(true, rows), addClusterSelectorTemplates(multi=true):: local d = self { @@ -379,7 +379,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; ) ) .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.queryPanel( ||| sum by(operation) ( diff --git a/cortex-mixin/dashboards/reads.libsonnet b/cortex-mixin/dashboards/reads.libsonnet index f741b188..927086f4 100644 --- a/cortex-mixin/dashboards/reads.libsonnet +++ b/cortex-mixin/dashboards/reads.libsonnet @@ -90,7 +90,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addRow( $.row('Gateway') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_request_duration_seconds_count{%s, route=~"(prometheus|api_prom)_api_v1_.+"}' % $.jobMatcher($._config.job_names.gateway)) + $.panelDescriptionRps('gateway') ) @@ -111,7 +111,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addRow( $.row('Query Frontend') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_request_duration_seconds_count{%s, route=~"(prometheus|api_prom)_api_v1_.+"}' % $.jobMatcher($._config.job_names.query_frontend)) + $.panelDescriptionRps('query frontend') ) @@ -146,7 +146,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; ) ) .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_query_scheduler_queue_duration_seconds_count{%s}' % $.jobMatcher($._config.job_names.query_scheduler)) + $.panelDescriptionRps('query scheduler') ) @@ -161,16 +161,14 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addPanel( $.textPanel('', |||

- The query results is an optional service is one of 4 - optional caches that can be deployed as part of a Cortex - cluster to improve query performance. - It is used by the query-frontend to cache entire results - of queries. + The query results cache is one of 4 optional caches + that can be deployed as part of a GEM cluster to improve query performance. + It is used by the query-frontend to cache entire results of queries.

|||) ) .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_cache_request_duration_seconds_count{method=~"frontend.+", %s}' % $.jobMatcher($._config.job_names.query_frontend)) + $.panelDescriptionRps('query results') ) @@ -183,7 +181,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addRow( $.row('Querier') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_querier_request_duration_seconds_count{%s, route=~"(prometheus|api_prom)_api_v1_.+"}' % $.jobMatcher($._config.job_names.querier)) + $.panelDescriptionRps( 'querier' @@ -217,7 +215,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; ) ) .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_request_duration_seconds_count{%s,route=~"/cortex.Ingester/Query(Stream)?|/cortex.Ingester/MetricsForLabelMatchers|/cortex.Ingester/LabelValues|/cortex.Ingester/MetricsMetadata"}' % $.jobMatcher($._config.job_names.ingester)) + $.panelDescriptionRps('ingester') ) @@ -252,7 +250,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; ) ) .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_request_duration_seconds_count{%s,route=~"/gatewaypb.StoreGateway/.*"}' % $.jobMatcher($._config.job_names.store_gateway)) + $.panelDescriptionRps('store gateway') ) @@ -274,7 +272,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.storage_engine, 'chunks'), $.row('Memcached - Chunks storage - Index') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_cache_request_duration_seconds_count{%s,method="store.index-cache-read.memcache.fetch"}' % $.jobMatcher($._config.job_names.querier)) ) .addPanel( @@ -286,7 +284,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.storage_engine, 'chunks'), $.row('Memcached - Chunks storage - Chunks') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_cache_request_duration_seconds_count{%s,method="chunksmemcache.fetch"}' % $.jobMatcher($._config.job_names.querier)) ) .addPanel( @@ -310,7 +308,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; ) ) .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.queryPanel( ||| sum by(operation) ( @@ -430,7 +428,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.chunk_index_backend + $._config.chunk_store_backend, 'cassandra'), $.row('Cassandra') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_cassandra_request_duration_seconds_count{%s, operation="SELECT"}' % $.jobMatcher($._config.job_names.querier)) ) .addPanel( @@ -443,7 +441,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.chunk_index_backend + $._config.chunk_store_backend, 'bigtable'), $.row('BigTable') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_bigtable_request_duration_seconds_count{%s, operation="/google.bigtable.v2.Bigtable/ReadRows"}' % $.jobMatcher($._config.job_names.querier)) ) .addPanel( @@ -456,7 +454,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.chunk_index_backend + $._config.chunk_store_backend, 'dynamodb'), $.row('DynamoDB') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_dynamo_request_duration_seconds_count{%s, operation="DynamoDB.QueryPages"}' % $.jobMatcher($._config.job_names.querier)) ) .addPanel( @@ -469,7 +467,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.chunk_store_backend, 'gcs'), $.row('GCS') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_gcs_request_duration_seconds_count{%s, operation="GET"}' % $.jobMatcher($._config.job_names.querier)) ) .addPanel( diff --git a/cortex-mixin/dashboards/writes.libsonnet b/cortex-mixin/dashboards/writes.libsonnet index cdf442ac..84c9ab6c 100644 --- a/cortex-mixin/dashboards/writes.libsonnet +++ b/cortex-mixin/dashboards/writes.libsonnet @@ -61,7 +61,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addRow( $.row('Gateway') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_request_duration_seconds_count{%s, route=~"api_(v1|prom)_push"}' % $.jobMatcher($._config.job_names.gateway)) + $.panelDescriptionRps('gateway') ) @@ -82,7 +82,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addRow( $.row('Distributor') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_request_duration_seconds_count{%s, route=~"/distributor.Distributor/Push|/httpgrpc.*|api_(v1|prom)_push"}' % $.jobMatcher($._config.job_names.distributor)) + $.panelDescriptionRps('distributor') ) @@ -103,7 +103,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addRow( $.row('KV Store (HA Dedupe)') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_kv_request_duration_seconds_count{%s}' % $.jobMatcher($._config.job_names.distributor)) + $.panelDescriptionRpsKvStoreDedupe() ) @@ -116,7 +116,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addRow( $.row('Ingester') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_request_duration_seconds_count{%s,route="/cortex.Ingester/Push"}' % $.jobMatcher($._config.job_names.ingester)) + $.panelDescriptionRps('ingester') ) @@ -137,7 +137,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; .addRow( $.row('KV Store (Ring)') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_kv_request_duration_seconds_count{%s}' % $.jobMatcher($._config.job_names.ingester)) + $.panelDescriptionRpsKvStoreRing() ) @@ -151,7 +151,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.storage_engine, 'chunks'), $.row('Memcached') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_memcache_request_duration_seconds_count{%s,method="Memcache.Put"}' % $.jobMatcher($._config.job_names.ingester)) ) .addPanel( @@ -164,7 +164,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.chunk_index_backend + $._config.chunk_store_backend, 'cassandra'), $.row('Cassandra') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_cassandra_request_duration_seconds_count{%s, operation="INSERT"}' % $.jobMatcher($._config.job_names.ingester)) ) .addPanel( @@ -177,7 +177,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.chunk_index_backend + $._config.chunk_store_backend, 'bigtable'), $.row('BigTable') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_bigtable_request_duration_seconds_count{%s, operation="/google.bigtable.v2.Bigtable/MutateRows"}' % $.jobMatcher($._config.job_names.ingester)) ) .addPanel( @@ -190,7 +190,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.chunk_index_backend + $._config.chunk_store_backend, 'dynamodb'), $.row('DynamoDB') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_dynamo_request_duration_seconds_count{%s, operation="DynamoDB.BatchWriteItem"}' % $.jobMatcher($._config.job_names.ingester)) ) .addPanel( @@ -203,7 +203,7 @@ local utils = import 'mixin-utils/utils.libsonnet'; std.member($._config.chunk_store_backend, 'gcs'), $.row('GCS') .addPanel( - $.panel('QPS') + + $.panel('Requests Per Second') + $.qpsPanel('cortex_gcs_request_duration_seconds_count{%s, operation="POST"}' % $.jobMatcher($._config.job_names.ingester)) ) .addPanel(