Skip to content

Commit

Permalink
ttl: add grafana chart for TTL events (#45645)
Browse files Browse the repository at this point in the history
ref #39848
  • Loading branch information
lcwangchao authored Jul 31, 2023
1 parent f2992f9 commit 9794ea5
Showing 1 changed file with 115 additions and 1 deletion.
116 changes: 115 additions & 1 deletion metrics/grafana/tidb.json
Original file line number Diff line number Diff line change
Expand Up @@ -19344,7 +19344,7 @@
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "Test-Cluster",
"datasource": "${DS_TEST-CLUSTER}",
"description": "TTL Schedule Delay is defined by \"MAX(0, now - lastSuccessJobTime - scheduleInterval)\"",
"fieldConfig": {
"defaults": {},
Expand Down Expand Up @@ -19599,6 +19599,120 @@
"timeShift": null,
"title": "TTL Insert/Delete Rows By Day",
"type": "bargauge"
},
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-CLUSTER}",
"description": "Count of event every minute for TTL",
"fieldConfig": {
"defaults": {},
"overrides": []
},
"fill": 0,
"fillGradient": 0,
"gridPos": {
"h": 8,
"w": 12,
"x": 0,
"y": 111
},
"hiddenSeries": false,
"id": 313,
"legend": {
"alignAsTable": true,
"avg": true,
"current": true,
"max": true,
"min": false,
"rightSide": true,
"show": true,
"total": false,
"values": true
},
"lines": true,
"linewidth": 1,
"nullPointMode": "null",
"options": {
"alertThreshold": true
},
"percentage": false,
"pluginVersion": "7.5.10",
"pointradius": 2,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"stack": false,
"steppedLine": false,
"targets": [
{
"exemplar": true,
"expr": "sum(increase(tidb_server_ttl_event_count{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\", instance=~\"$instance\"}[1m])) by (type)",
"interval": "",
"legendFormat": "ttl-{{ type }}",
"queryType": "randomWalk",
"refId": "A"
},
{
"exemplar": true,
"expr": "sum(increase(tidb_server_timer_event_count{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\", instance=~\"$instance\", scope=\"hook.tidb.ttl\"}[1m])) by (type)",
"hide": false,
"interval": "",
"legendFormat": "hook-{{ type }}",
"refId": "B"
},
{
"exemplar": true,
"expr": "sum(increase(tidb_server_timer_event_count{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\", instance=~\"$instance\", scope=~\"runtime\\\\.ttl.*\"}[1m])) by (type)",
"hide": false,
"interval": "",
"legendFormat": "runtime-{{ type }}",
"refId": "C"
}
],
"thresholds": [],
"timeFrom": null,
"timeRegions": [],
"timeShift": null,
"title": "TTL Event Count Per Minute",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": "0",
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": false
}
],
"yaxis": {
"align": false,
"alignLevel": null
}
}
],
"title": "TTL",
Expand Down

0 comments on commit 9794ea5

Please sign in to comment.