Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
e40d232a
Commit
e40d232a
authored
Jun 21, 2024
by
Sergei Petrunia
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Stabilize analyze_engine_stats2.test
parent
513c8270
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
34 deletions
+10
-34
mysql-test/main/analyze_engine_stats2.opt
mysql-test/main/analyze_engine_stats2.opt
+1
-1
mysql-test/main/analyze_engine_stats2.result
mysql-test/main/analyze_engine_stats2.result
+4
-29
mysql-test/main/analyze_engine_stats2.test
mysql-test/main/analyze_engine_stats2.test
+5
-4
No files found.
mysql-test/main/analyze_engine_stats2.opt
View file @
e40d232a
--innodb
_buffer_pool_dump_at_shutdown=off --innodb_buffer_pool_load_at_startup=off --innodb-stats-persistent=1
--innodb-stats-auto-recalc=off
--innodb
-buffer-pool-size=32M --innodb_buffer_pool_dump_at_shutdown=off --innodb_buffer_pool_load_at_startup=off --innodb-stats-persistent=1
--innodb-stats-auto-recalc=off
mysql-test/main/analyze_engine_stats2.result
View file @
e40d232a
...
...
@@ -8,45 +8,20 @@ c varchar(255),
d varchar(255),
primary key(a,b,c,d)
) engine=innodb;
SET unique_checks=0, foreign_key_checks= 0;
begin;
insert into t1 select
repeat(uuid(), 7),
repeat(uuid(), 7),
repeat(uuid(), 7),
repeat(uuid(), 7)
from seq_1_to_16384;
commit;
SET GLOBAL innodb_fast_shutdown=0;
# restart
set log_slow_verbosity='engine';
set long_query_time=0.0;
set @js='$analyze_output';
select @js;
@js
{
"query_block": {
"select_id": 1,
"r_loops": 1,
"r_total_time_ms": "REPLACED",
"table": {
"table_name": "t1",
"access_type": "index",
"key": "PRIMARY",
"key_length": "1028",
"used_key_parts": ["a", "b", "c", "d"],
"r_loops": 1,
"rows": 1,
"r_rows": 16384,
"r_table_time_ms": "REPLACED",
"r_other_time_ms": "REPLACED",
"r_engine_stats": {
"pages_accessed": "REPLACED",
"pages_read_count": "REPLACED",
"pages_read_time_ms": "REPLACED"
},
"filtered": 100,
"r_filtered": 100,
"using_index": true
}
}
}
set @pages_read_time_ms=
(select json_value(@js,'$.query_block.table.r_engine_stats.pages_read_time_ms'));
...
...
mysql-test/main/analyze_engine_stats2.test
View file @
e40d232a
...
...
@@ -18,6 +18,9 @@ create table t1 (
primary
key
(
a
,
b
,
c
,
d
)
)
engine
=
innodb
;
SET
unique_checks
=
0
,
foreign_key_checks
=
0
;
begin
;
# The data size is 160K * 1K = 160M
# 16M / (page_size=16K) = 1K pages.
insert
into
t1
select
...
...
@@ -26,7 +29,9 @@ insert into t1 select
repeat
(
uuid
(),
7
),
repeat
(
uuid
(),
7
)
from
seq_1_to_16384
;
commit
;
SET
GLOBAL
innodb_fast_shutdown
=
0
;
source
include
/
restart_mysqld
.
inc
;
set
log_slow_verbosity
=
'engine'
;
set
long_query_time
=
0.0
;
...
...
@@ -35,10 +40,6 @@ let $analyze_output= `analyze format=json
select * from t1 force index (PRIMARY) order by a desc, b desc, c desc, d desc`
;
evalp
set
@
js
=
'$analyze_output'
;
# Print it out for user-friendlines
--
replace_regex
/
(
"(r_[a-z_]*_time_ms|pages[^"
]
*
)
": )[^,
\n
]*/
\1
"
REPLACED
"/
select @js;
set
@
pages_read_time_ms
=
(
select
json_value
(
@
js
,
'$.query_block.table.r_engine_stats.pages_read_time_ms'
));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment