Skip to content

Commit

Permalink
polish cos (#438)
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasgameiroborges authored Jan 9, 2025
1 parent a3567a0 commit fcb04d1
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions src/grafana_dashboards/pgbouncer-metrics.json
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@
"steppedLine": false,
"targets": [
{
"expr": "sum (rate(pgbouncer_databases_reserve_pool_size{database=~\"$db\"}[30m]))",
"expr": "sum (pgbouncer_databases_reserve_pool{database=~\"$db\"})",
"format": "time_series",
"interval": "",
"intervalFactor": 1,
Expand Down Expand Up @@ -508,7 +508,7 @@
"steppedLine": false,
"targets": [
{
"expr": "sort_desc( sum ( rate(pgbouncer_stats_queries_duration_seconds_total{database=\"$db\"}[30m]) ) )",
"expr": "sort_desc( sum ( irate(pgbouncer_stats_queries_duration_seconds_total{database=~\"$db\"}[30m]) ) )",
"format": "time_series",
"interval": "",
"intervalFactor": 1,
Expand Down Expand Up @@ -618,16 +618,16 @@
"steppedLine": false,
"targets": [
{
"expr": "sort_desc( sum ( rate(pgbouncer_stats_queries_duration_seconds_total{database=~\"$db\"}[30m]) ) )",
"expr": "sort_desc( sum ( irate(pgbouncer_stats_queries_duration_seconds_total{database=~\"$db\"}[30m]) ) ) * 1000",
"format": "time_series",
"hide": false,
"interval": "",
"intervalFactor": 1,
"legendFormat": "Duration microseconds",
"legendFormat": "Query duration microseconds",
"refId": "B"
},
{
"expr": "sort_desc( sum ( rate(pgbouncer_pools_client_maxwait_seconds{database=~\"$db\"}[30m]) ) ) ",
"expr": "sort_desc( sum ( irate(pgbouncer_stats_client_wait_seconds_total{database=~\"$db\"}[30m]) ) ) * 1000",
"format": "time_series",
"interval": "",
"intervalFactor": 1,
Expand All @@ -639,7 +639,7 @@
"timeFrom": null,
"timeRegions": [],
"timeShift": null,
"title": "Stats queries",
"title": "Queries (execution and waiting durations)",
"tooltip": {
"shared": true,
"sort": 0,
Expand Down Expand Up @@ -735,27 +735,27 @@
"steppedLine": false,
"targets": [
{
"expr": "sort_desc( sum ( rate(pgbouncer_stats_server_in_transaction_seconds{database=~\"$db\"}[30m]) ) ) ",
"expr": "sort_desc( sum ( irate(pgbouncer_stats_server_in_transaction_seconds_total{database=~\"$db\"}[30m]) ) ) * 1000 ",
"format": "time_series",
"interval": "",
"intervalFactor": 1,
"legendFormat": "Transactions duration microseconds",
"refId": "D"
},
{
"expr": "sort_desc( sum ( rate(pgbouncer_stats_sql_transactions_pooled_total{database=~\"$db\"}[30m]) ) )",
"expr": "sort_desc( sum ( irate(pgbouncer_stats_sql_transactions_pooled_total{database=~\"$db\"}[30m]) ) )",
"format": "time_series",
"interval": "",
"intervalFactor": 1,
"legendFormat": "Transactions total",
"legendFormat": "Transactions count",
"refId": "A"
}
],
"thresholds": [],
"timeFrom": null,
"timeRegions": [],
"timeShift": null,
"title": "Transactions stats",
"title": "Transactions (duration and count)",
"tooltip": {
"shared": true,
"sort": 0,
Expand Down Expand Up @@ -1018,7 +1018,7 @@
"steppedLine": false,
"targets": [
{
"expr": "sort_desc( sum ( rate(pgbouncer_stats_received_bytes_total{database=~\"$db\"}[30m])*8 ) )",
"expr": "sort_desc( sum ( irate(pgbouncer_stats_received_bytes_total{database=~\"$db\"}[30m])*8 ) )",
"format": "time_series",
"hide": false,
"interval": "",
Expand All @@ -1027,7 +1027,7 @@
"refId": "B"
},
{
"expr": "sort_desc( sum ( rate(pgbouncer_stats_sent_bytes_total{database=~\"$db\"}[30m])*8 ) )",
"expr": "sort_desc( sum ( irate(pgbouncer_stats_sent_bytes_total{database=~\"$db\"}[30m])*8 ) )",
"format": "time_series",
"interval": "",
"intervalFactor": 1,
Expand Down

0 comments on commit fcb04d1

Please sign in to comment.