Skip to content

Commit 0a55d45

Browse files
Merge branch 'v3' into PMM-10308-Mysql-Instance-Summary-Dashboard-multiple-panels-do-not-have-data
2 parents 2231037 + 92dc0a5 commit 0a55d45

File tree

3 files changed

+52
-14
lines changed

3 files changed

+52
-14
lines changed

pmm-app/src/pmm-qan/panel/QueryAnalytics.constants.test.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,14 @@ const metrics = {
110110
};
111111

112112
const EMPTY_RELATIONS_METRICS = [
113-
'blk_read_time',
114-
'blk_write_time',
113+
'local_blk_read_time',
114+
'local_blk_write_time',
115115
'local_blks_dirtied',
116116
'local_blks_hit',
117117
'local_blks_read',
118118
'local_blks_written',
119+
'shared_blk_read_time',
120+
'shared_blk_write_time',
119121
'shared_blks_dirtied',
120122
'shared_blks_hit',
121123
'shared_blks_read',

pmm-app/src/pmm-qan/panel/QueryAnalytics.constants.ts

Lines changed: 40 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,11 @@ export const METRIC_CATALOGUE = {
6969
perQueryStatsPipe: 'size',
7070
},
7171
},
72-
blk_read_time: {
73-
humanizeName: 'Reading Blocks Time',
72+
local_blk_read_time: {
73+
humanizeName: 'Reading Local Blocks Time',
7474
tooltipText:
75-
'Total time the statement spent reading blocks (if track_io_timing is enabled, otherwise zero)',
76-
simpleName: 'blk_read_time',
75+
'Total time the statement spent reading local blocks (if track_io_timing is enabled, otherwise zero)',
76+
simpleName: 'local_blk_read_time',
7777
serviceTypes: [Databases.postgresql],
7878
metricRelation: () => '',
7979
units: Units.PER_SEC,
@@ -85,11 +85,11 @@ export const METRIC_CATALOGUE = {
8585
perQueryStatsPipe: 'time',
8686
},
8787
},
88-
blk_write_time: {
89-
humanizeName: 'Writing Blocks Time',
88+
local_blk_write_time: {
89+
humanizeName: 'Writing Local Blocks Time',
9090
tooltipText:
91-
'Total time the statement spent writing blocks (if track_io_timing is enabled, otherwise zero)',
92-
simpleName: 'blk_write_time',
91+
'Total time the statement spent writing local blocks (if track_io_timing is enabled, otherwise zero)',
92+
simpleName: 'local_blk_write_time',
9393
serviceTypes: [Databases.postgresql],
9494
metricRelation: () => '',
9595
units: Units.PER_SEC,
@@ -176,6 +176,38 @@ export const METRIC_CATALOGUE = {
176176
perQueryStatsPipe: 'number',
177177
},
178178
},
179+
shared_blk_read_time: {
180+
humanizeName: 'Reading Shared Blocks Time',
181+
tooltipText:
182+
'Total time the statement spent reading shared blocks (if track_io_timing is enabled, otherwise zero)',
183+
simpleName: 'shared_blk_read_time',
184+
serviceTypes: [Databases.postgresql],
185+
metricRelation: () => '',
186+
units: Units.PER_SEC,
187+
pipeTypes: {
188+
ratePipe: 'number',
189+
sumPipe: 'time',
190+
subSumPipe: 'percent',
191+
sparklineType: 'number',
192+
perQueryStatsPipe: 'time',
193+
},
194+
},
195+
shared_blk_write_time: {
196+
humanizeName: 'Writing Shared Blocks Time',
197+
tooltipText:
198+
'Total time the statement spent writing shared blocks (if track_io_timing is enabled, otherwise zero)',
199+
simpleName: 'shared_blk_write_time',
200+
serviceTypes: [Databases.postgresql],
201+
metricRelation: () => '',
202+
units: Units.PER_SEC,
203+
pipeTypes: {
204+
ratePipe: 'number',
205+
sumPipe: 'time',
206+
subSumPipe: 'percent',
207+
sparklineType: 'number',
208+
perQueryStatsPipe: 'time',
209+
},
210+
},
179211
shared_blks_hit: {
180212
humanizeName: 'Shared Block Cache Hits',
181213
tooltipText: 'Total number of shared block cache hits by the statement',
Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,30 @@
11
export const TIME_METRICS = [
22
'lock_time',
33
'query_time',
4-
'blk_read_time',
5-
'blk_write_time',
64
'innodb_io_r_wait',
75
'innodb_queue_wait',
86
'innodb_rec_lock_wait',
97
// PG metrics
108
'cpu_user_time',
119
'cpu_sys_time',
10+
'local_blk_read_time',
11+
'local_blk_write_time',
12+
'shared_blk_read_time',
13+
'shared_blk_write_time',
1214
];
1315

1416
export const METRICS_COLORS = {
1517
lock_time: '#BD4848',
16-
blk_read_time: '#4e378c',
17-
blk_write_time: '#fcc200',
1818
innodb_io_r_wait: '#3c3c3c',
1919
innodb_queue_wait: '#7e4291',
2020
innodb_rec_lock_wait: '#e97e03',
2121
// PG metrics
2222
cpu_user_time: '#a87067',
2323
cpu_sys_time: '#23b899',
24+
local_blk_read_time: '#4e378c',
25+
local_blk_write_time: '#fcc200',
26+
shared_blk_read_time: '#4e378c',
27+
shared_blk_write_time: '#fcc200',
2428
};
2529

2630
export const PERCENT_COUNT = 100;

0 commit comments

Comments
 (0)