Skip to content

Commit

Permalink
fix promQL
Browse files Browse the repository at this point in the history
  • Loading branch information
djshow832 committed Dec 19, 2023
1 parent 5187ab3 commit 0856a85
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pkg/metrics/grafana/tiproxy_summary.json
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@
"steppedLine": false,
"targets": [
{
"expr": "sum(increase(tiproxy_server_create_connection_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\", instance=~\"$instance\"}[1m]))",
"expr": "sum(increase(tiproxy_server_create_connection_total{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\", instance=~\"$instance\"}[1m])) by (instance)",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "{{instance}}",
Expand Down
2 changes: 1 addition & 1 deletion pkg/metrics/grafana/tiproxy_summary.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ local createConnP = graphPanel.new(
)
.addTarget(
prometheus.target(
'sum(increase(tiproxy_server_create_connection_total{k8s_cluster="$k8s_cluster", tidb_cluster="$tidb_cluster", instance=~"$instance"}[1m]))',
'sum(increase(tiproxy_server_create_connection_total{k8s_cluster="$k8s_cluster", tidb_cluster="$tidb_cluster", instance=~"$instance"}[1m])) by (instance)',
legendFormat='{{instance}}',
)
);
Expand Down

0 comments on commit 0856a85

Please sign in to comment.