Skip to content

Commit

Permalink
store/tikv: add 1PC grafana panel and lower 1PC log level (#22943)
Browse files Browse the repository at this point in the history
  • Loading branch information
sticnarf authored Feb 26, 2021
1 parent 4a413a4 commit 5d8b99f
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 49 deletions.
98 changes: 50 additions & 48 deletions metrics/grafana/tidb.json
Original file line number Diff line number Diff line change
Expand Up @@ -3591,19 +3591,19 @@
},
"type": "heatmap",
"xAxis": {
"show": true
},
"show": true
},
"xBucketNumber": null,
"xBucketSize": null,
"yAxis": {
"decimals": 0,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"show": true,
"splitFactor": null
},
},
"yBucketBound": "auto",
"yBucketNumber": null,
"yBucketSize": null
Expand Down Expand Up @@ -3658,19 +3658,19 @@
},
"type": "heatmap",
"xAxis": {
"show": true
},
"show": true
},
"xBucketNumber": null,
"xBucketSize": null,
"yAxis": {
"decimals": 0,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"show": true,
"splitFactor": null
},
},
"yBucketBound": "auto",
"yBucketNumber": null,
"yBucketSize": null
Expand Down Expand Up @@ -4129,19 +4129,19 @@
},
"type": "heatmap",
"xAxis": {
"show": true
},
"show": true
},
"xBucketNumber": null,
"xBucketSize": null,
"yAxis": {
"decimals": 0,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"show": true,
"splitFactor": null
},
},
"yBucketBound": "auto",
"yBucketNumber": null,
"yBucketSize": null
Expand Down Expand Up @@ -4306,16 +4306,16 @@
},
"type": "heatmap",
"xAxis": {
"show": true
},
"show": true
},
"xBucketNumber": null,
"xBucketSize": null,
"yAxis": {
"decimals": 0,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"logBase": 1,
"max": null,
"min": null,
"show": true,
"splitFactor": null
},
Expand Down Expand Up @@ -4374,19 +4374,19 @@
},
"type": "heatmap",
"xAxis": {
"show": true
},
"show": true
},
"xBucketNumber": null,
"xBucketSize": null,
"yAxis": {
"decimals": 0,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"show": true,
"splitFactor": null
},
},
"yBucketBound": "auto",
"yBucketNumber": null,
"yBucketSize": null
Expand Down Expand Up @@ -5040,16 +5040,16 @@
},
"type": "heatmap",
"xAxis": {
"show": true
},
"show": true
},
"xBucketNumber": null,
"xBucketSize": null,
"yAxis": {
"decimals": 0,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"format": "short",
"logBase": 1,
"max": null,
"min": null,
"show": true,
"splitFactor": null
},
Expand Down Expand Up @@ -5107,8 +5107,15 @@
"expr": "sum(rate(tidb_tikvclient_async_commit_txn_counter{tidb_cluster=\"$tidb_cluster\"}[1m])) by (type)",
"format": "time_series",
"intervalFactor": 1,
"legendFormat": "{{type}}",
"legendFormat": "async commit-{{type}}",
"refId": "A"
},
{
"refId": "B",
"expr": "sum(rate(tidb_tikvclient_one_pc_txn_counter{tidb_cluster=\"$tidb_cluster\"}[1m])) by (type)",
"intervalFactor": 1,
"format": "time_series",
"legendFormat": "1PC-{{type}}"
}
],
"thresholds": [],
Expand Down Expand Up @@ -11937,25 +11944,20 @@
"list": [
{
"allValue": null,
"current": {
},
"current": {},
"datasource": "${DS_TEST-CLUSTER}",
"hide": 2,
"includeAll": false,
"label": "tidb_cluster",
"multi": false,
"name": "tidb_cluster",
"options": [

],
"options": [],
"query": "label_values(pd_cluster_status, tidb_cluster)",
"refresh": 2,
"regex": "",
"sort": 1,
"tagValuesQuery": "",
"tags": [

],
"tags": [],
"tagsQuery": "",
"type": "query",
"useTags": false
Expand Down
2 changes: 1 addition & 1 deletion store/tikv/2pc.go
Original file line number Diff line number Diff line change
Expand Up @@ -1189,7 +1189,7 @@ func (c *twoPhaseCommitter) execute(ctx context.Context) (err error) {
}
c.commitTS = c.onePCCommitTS
c.txn.commitTS = c.commitTS
logutil.Logger(ctx).Info("1PC protocol is used to commit this txn",
logutil.Logger(ctx).Debug("1PC protocol is used to commit this txn",
zap.Uint64("startTS", c.startTS), zap.Uint64("commitTS", c.commitTS),
zap.Uint64("session", c.sessionID))
return nil
Expand Down

0 comments on commit 5d8b99f

Please sign in to comment.