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
bdcce58f
Commit
bdcce58f
authored
Jul 04, 2017
by
Aleksey Midenkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
IB: long names in information_schema
parent
72de7721
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
137 additions
and
117 deletions
+137
-117
mysql-test/suite/versioning/common.inc
mysql-test/suite/versioning/common.inc
+7
-7
mysql-test/suite/versioning/r/alter.result
mysql-test/suite/versioning/r/alter.result
+7
-7
mysql-test/suite/versioning/r/auto_increment.result
mysql-test/suite/versioning/r/auto_increment.result
+7
-7
mysql-test/suite/versioning/r/commit_id.result
mysql-test/suite/versioning/r/commit_id.result
+21
-21
mysql-test/suite/versioning/r/create.result
mysql-test/suite/versioning/r/create.result
+7
-7
mysql-test/suite/versioning/r/ddl.result
mysql-test/suite/versioning/r/ddl.result
+7
-7
mysql-test/suite/versioning/r/delete.result
mysql-test/suite/versioning/r/delete.result
+7
-7
mysql-test/suite/versioning/r/insert.result
mysql-test/suite/versioning/r/insert.result
+7
-7
mysql-test/suite/versioning/r/partition.result
mysql-test/suite/versioning/r/partition.result
+7
-7
mysql-test/suite/versioning/r/select.result
mysql-test/suite/versioning/r/select.result
+7
-7
mysql-test/suite/versioning/r/update.result
mysql-test/suite/versioning/r/update.result
+7
-7
mysql-test/suite/versioning/t/commit_id.test
mysql-test/suite/versioning/t/commit_id.test
+7
-7
storage/innobase/handler/i_s.cc
storage/innobase/handler/i_s.cc
+39
-19
No files found.
mysql-test/suite/versioning/common.inc
View file @
bdcce58f
set
@@
session
.
time_zone
=
'+00:00'
;
select
ifnull
(
max
(
tr
x
_id
),
0
)
into
@
start_trx_id
from
information_schema
.
innodb_vtq
;
select
ifnull
(
max
(
tr
ansaction
_id
),
0
)
into
@
start_trx_id
from
information_schema
.
innodb_vtq
;
delimiter
~~
;
create
procedure
if
not
exists
verify_vtq
()
...
...
@@ -7,13 +7,13 @@ begin
set
@
i
=
0
;
select
@
i
:=
@
i
+
1
as
No
,
tr
x
_id
>
0
as
A
,
commit_id
>
tr
x
_id
as
B
,
begin_t
s
>
'1-1-1 0:0:0'
as
C
,
commit_t
s
>=
begin_ts
as
D
tr
ansaction
_id
>
0
as
A
,
commit_id
>
tr
ansaction
_id
as
B
,
begin_t
imestamp
>
'1-1-1 0:0:0'
as
C
,
commit_t
imestamp
>=
begin_timestamp
as
D
from
information_schema
.
innodb_vtq
where
tr
x
_id
>
@
start_trx_id
;
select
ifnull
(
max
(
tr
x
_id
),
0
)
where
tr
ansaction
_id
>
@
start_trx_id
;
select
ifnull
(
max
(
tr
ansaction
_id
),
0
)
into
@
start_trx_id
from
information_schema
.
innodb_vtq
;
end
~~
...
...
mysql-test/suite/versioning/r/alter.result
View file @
bdcce58f
...
...
@@ -251,19 +251,19 @@ t CREATE TABLE `t` (
PERIOD FOR SYSTEM_TIME (`sys_trx_start`, `sys_trx_end`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 WITH SYSTEM VERSIONING
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/r/auto_increment.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/r/commit_id.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
@@ -68,20 +68,20 @@ insert into t1 values ();
set @ts0= now(6);
insert into t1 values ();
select sys_trx_start from t1 where id = last_insert_id() into @tx0;
select tr
x
_id = @tx0 from information_schema.innodb_vtq limit 1;
tr
x
_id = @tx0
select tr
ansaction
_id = @tx0 from information_schema.innodb_vtq limit 1;
tr
ansaction
_id = @tx0
1
set @ts1= now(6);
insert into t1 values ();
select sys_trx_start from t1 where id = last_insert_id() into @tx1;
select tr
x
_id = @tx1 from information_schema.innodb_vtq limit 1;
tr
x
_id = @tx1
select tr
ansaction
_id = @tx1 from information_schema.innodb_vtq limit 1;
tr
ansaction
_id = @tx1
1
set @ts2= now(6);
insert into t1 values ();
select sys_trx_start from t1 where id = last_insert_id() into @tx2;
select tr
x
_id = @tx2 from information_schema.innodb_vtq limit 1;
tr
x
_id = @tx2
select tr
ansaction
_id = @tx2 from information_schema.innodb_vtq limit 1;
tr
ansaction
_id = @tx2
1
set @ts3= now(6);
select
...
...
@@ -119,26 +119,26 @@ A B C D E F H
set transaction isolation level read uncommitted;
insert into t1 values ();
select sys_trx_start from t1 where id = last_insert_id() into @tx3;
select iso
_level = 'RU' from information_schema.innodb_vtq where trx
_id = @tx3;
iso
_level = 'RU
'
select iso
lation_level = 'READ-UNCOMMITTED' from information_schema.innodb_vtq where transaction
_id = @tx3;
iso
lation_level = 'READ-UNCOMMITTED
'
1
set transaction isolation level read committed;
insert into t1 values ();
select sys_trx_start from t1 where id = last_insert_id() into @tx4;
select iso
_level = 'RC' from information_schema.innodb_vtq where trx
_id = @tx4;
iso
_level = 'RC
'
select iso
lation_level = 'READ-COMMITTED' from information_schema.innodb_vtq where transaction
_id = @tx4;
iso
lation_level = 'READ-COMMITTED
'
1
set transaction isolation level serializable;
insert into t1 values ();
select sys_trx_start from t1 where id = last_insert_id() into @tx5;
select iso
_level = 'S' from information_schema.innodb_vtq where trx
_id = @tx5;
iso
_level = 'S
'
select iso
lation_level = 'SERIALIZABLE' from information_schema.innodb_vtq where transaction
_id = @tx5;
iso
lation_level = 'SERIALIZABLE
'
1
set transaction isolation level repeatable read;
insert into t1 values ();
select sys_trx_start from t1 where id = last_insert_id() into @tx6;
select iso
_level = 'RR' from information_schema.innodb_vtq where trx
_id = @tx6;
iso
_level = 'RR
'
select iso
lation_level = 'REPEATABLE-READ' from information_schema.innodb_vtq where transaction
_id = @tx6;
iso
lation_level = 'REPEATABLE-READ
'
1
drop table t1;
call verify_vtq;
...
...
mysql-test/suite/versioning/r/create.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/r/ddl.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/r/delete.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/r/insert.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/r/partition.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/r/select.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/r/update.result
View file @
bdcce58f
set @@session.time_zone='+00:00';
select ifnull(max(tr
x
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
select ifnull(max(tr
ansaction
_id), 0) into @start_trx_id from information_schema.innodb_vtq;
create procedure if not exists verify_vtq()
begin
set @i= 0;
select
@i:= @i + 1 as No,
tr
x
_id > 0 as A,
commit_id > tr
x
_id as B,
begin_t
s
> '1-1-1 0:0:0' as C,
commit_t
s >= begin_ts
as D
tr
ansaction
_id > 0 as A,
commit_id > tr
ansaction
_id as B,
begin_t
imestamp
> '1-1-1 0:0:0' as C,
commit_t
imestamp >= begin_timestamp
as D
from information_schema.innodb_vtq
where tr
x
_id > @start_trx_id;
select ifnull(max(tr
x
_id), 0)
where tr
ansaction
_id > @start_trx_id;
select ifnull(max(tr
ansaction
_id), 0)
into @start_trx_id
from information_schema.innodb_vtq;
end~~
...
...
mysql-test/suite/versioning/t/commit_id.test
View file @
bdcce58f
...
...
@@ -13,17 +13,17 @@ insert into t1 values ();
set
@
ts0
=
now
(
6
);
insert
into
t1
values
();
select
sys_trx_start
from
t1
where
id
=
last_insert_id
()
into
@
tx0
;
select
tr
x
_id
=
@
tx0
from
information_schema
.
innodb_vtq
limit
1
;
select
tr
ansaction
_id
=
@
tx0
from
information_schema
.
innodb_vtq
limit
1
;
set
@
ts1
=
now
(
6
);
insert
into
t1
values
();
select
sys_trx_start
from
t1
where
id
=
last_insert_id
()
into
@
tx1
;
select
tr
x
_id
=
@
tx1
from
information_schema
.
innodb_vtq
limit
1
;
select
tr
ansaction
_id
=
@
tx1
from
information_schema
.
innodb_vtq
limit
1
;
set
@
ts2
=
now
(
6
);
insert
into
t1
values
();
select
sys_trx_start
from
t1
where
id
=
last_insert_id
()
into
@
tx2
;
select
tr
x
_id
=
@
tx2
from
information_schema
.
innodb_vtq
limit
1
;
select
tr
ansaction
_id
=
@
tx2
from
information_schema
.
innodb_vtq
limit
1
;
set
@
ts3
=
now
(
6
);
...
...
@@ -62,22 +62,22 @@ select
set
transaction
isolation
level
read
uncommitted
;
insert
into
t1
values
();
select
sys_trx_start
from
t1
where
id
=
last_insert_id
()
into
@
tx3
;
select
iso
_level
=
'RU'
from
information_schema
.
innodb_vtq
where
trx
_id
=
@
tx3
;
select
iso
lation_level
=
'READ-UNCOMMITTED'
from
information_schema
.
innodb_vtq
where
transaction
_id
=
@
tx3
;
set
transaction
isolation
level
read
committed
;
insert
into
t1
values
();
select
sys_trx_start
from
t1
where
id
=
last_insert_id
()
into
@
tx4
;
select
iso
_level
=
'RC'
from
information_schema
.
innodb_vtq
where
trx
_id
=
@
tx4
;
select
iso
lation_level
=
'READ-COMMITTED'
from
information_schema
.
innodb_vtq
where
transaction
_id
=
@
tx4
;
set
transaction
isolation
level
serializable
;
insert
into
t1
values
();
select
sys_trx_start
from
t1
where
id
=
last_insert_id
()
into
@
tx5
;
select
iso
_level
=
'S'
from
information_schema
.
innodb_vtq
where
trx
_id
=
@
tx5
;
select
iso
lation_level
=
'SERIALIZABLE'
from
information_schema
.
innodb_vtq
where
transaction
_id
=
@
tx5
;
set
transaction
isolation
level
repeatable
read
;
insert
into
t1
values
();
select
sys_trx_start
from
t1
where
id
=
last_insert_id
()
into
@
tx6
;
select
iso
_level
=
'RR'
from
information_schema
.
innodb_vtq
where
trx
_id
=
@
tx6
;
select
iso
lation_level
=
'REPEATABLE-READ'
from
information_schema
.
innodb_vtq
where
transaction
_id
=
@
tx6
;
drop
table
t1
;
...
...
storage/innobase/handler/i_s.cc
View file @
bdcce58f
...
...
@@ -9661,7 +9661,7 @@ UNIV_INTERN struct st_maria_plugin i_s_innodb_sys_semaphore_waits =
static
ST_FIELD_INFO
innodb_vtq_fields_info
[]
=
{
#define SYS_VTQ_TRX_ID 0
{
STRUCT_FLD
(
field_name
,
"tr
x
_id"
),
{
STRUCT_FLD
(
field_name
,
"tr
ansaction
_id"
),
STRUCT_FLD
(
field_length
,
MY_INT64_NUM_DECIMAL_DIGITS
),
STRUCT_FLD
(
field_type
,
MYSQL_TYPE_LONGLONG
),
STRUCT_FLD
(
value
,
0
),
...
...
@@ -9679,7 +9679,7 @@ static ST_FIELD_INFO innodb_vtq_fields_info[] =
STRUCT_FLD
(
open_method
,
SKIP_OPEN_TABLE
)
},
#define SYS_VTQ_BEGIN_TS 2
{
STRUCT_FLD
(
field_name
,
"begin_t
s
"
),
{
STRUCT_FLD
(
field_name
,
"begin_t
imestamp
"
),
STRUCT_FLD
(
field_length
,
6
),
STRUCT_FLD
(
field_type
,
MYSQL_TYPE_TIMESTAMP
),
STRUCT_FLD
(
value
,
0
),
...
...
@@ -9688,7 +9688,7 @@ static ST_FIELD_INFO innodb_vtq_fields_info[] =
STRUCT_FLD
(
open_method
,
SKIP_OPEN_TABLE
)
},
#define SYS_VTQ_COMMIT_TS 3
{
STRUCT_FLD
(
field_name
,
"commit_t
s
"
),
{
STRUCT_FLD
(
field_name
,
"commit_t
imestamp
"
),
STRUCT_FLD
(
field_length
,
6
),
STRUCT_FLD
(
field_type
,
MYSQL_TYPE_TIMESTAMP
),
STRUCT_FLD
(
value
,
0
),
...
...
@@ -9697,8 +9697,8 @@ static ST_FIELD_INFO innodb_vtq_fields_info[] =
STRUCT_FLD
(
open_method
,
SKIP_OPEN_TABLE
)
},
#define SYS_VTQ_ISO_LEVEL 4
{
STRUCT_FLD
(
field_name
,
"iso_level"
),
STRUCT_FLD
(
field_length
,
2
),
{
STRUCT_FLD
(
field_name
,
"iso
lation
_level"
),
STRUCT_FLD
(
field_length
,
16
),
STRUCT_FLD
(
field_type
,
MYSQL_TYPE_STRING
),
STRUCT_FLD
(
value
,
0
),
STRUCT_FLD
(
field_flags
,
0
),
...
...
@@ -9708,6 +9708,39 @@ static ST_FIELD_INFO innodb_vtq_fields_info[] =
END_OF_ST_FIELD_INFO
};
/******************************************************************//**
Maps a InnoDB trx isolation level code to the MySQL isolation level name
@return MySQL isolation level name */
static
inline
const
char
*
i_s_isolation_name
(
/*=========================*/
ulint
iso
)
/*!< in: InnoDB isolation level code */
{
enum_tx_isolation
mysql_iso
;
switch
(
iso
)
{
case
TRX_ISO_REPEATABLE_READ
:
mysql_iso
=
ISO_REPEATABLE_READ
;
break
;
case
TRX_ISO_READ_COMMITTED
:
mysql_iso
=
ISO_READ_COMMITTED
;
break
;
case
TRX_ISO_SERIALIZABLE
:
mysql_iso
=
ISO_SERIALIZABLE
;
break
;
case
TRX_ISO_READ_UNCOMMITTED
:
mysql_iso
=
ISO_READ_UNCOMMITTED
;
break
;
default:
ut_error
;
return
NULL
;
}
return
tx_isolation_names
[
mysql_iso
];
}
/**********************************************************************//**
Function to fill INFORMATION_SCHEMA.INNODB_SYS_VTQ with information
collected by scanning SYS_VTQ table.
...
...
@@ -9726,20 +9759,7 @@ i_s_dict_fill_vtq(
DBUG_ENTER
(
"i_s_dict_fill_vtq"
);
fields
=
table_to_fill
->
field
;
switch
(
vtq
.
iso_level
)
{
case
TRX_ISO_REPEATABLE_READ
:
iso_level
=
"RR"
;
break
;
case
TRX_ISO_READ_COMMITTED
:
iso_level
=
"RC"
;
break
;
case
TRX_ISO_SERIALIZABLE
:
iso_level
=
"S"
;
break
;
case
TRX_ISO_READ_UNCOMMITTED
:
iso_level
=
"RU"
;
break
;
}
iso_level
=
i_s_isolation_name
(
vtq
.
iso_level
);
OK
(
field_store_ullong
(
fields
[
SYS_VTQ_TRX_ID
],
vtq
.
trx_id
));
OK
(
field_store_ullong
(
fields
[
SYS_VTQ_COMMIT_ID
],
vtq
.
commit_id
));
...
...
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