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
90a306a7
Commit
90a306a7
authored
Apr 27, 2021
by
Marko Mäkelä
Browse files
Options
Browse Files
Download
Plain Diff
Merge 10.3 into 10.4
parents
9e6310e3
29b2f3db
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
257 additions
and
4 deletions
+257
-4
mysql-test/main/subselect4.result
mysql-test/main/subselect4.result
+61
-0
mysql-test/main/subselect4.test
mysql-test/main/subselect4.test
+45
-0
mysql-test/suite/innodb/r/default_row_format_alter.result
mysql-test/suite/innodb/r/default_row_format_alter.result
+11
-0
mysql-test/suite/innodb/t/default_row_format_alter.test
mysql-test/suite/innodb/t/default_row_format_alter.test
+15
-0
mysql-test/suite/rpl/r/rpl_semi_sync_slave_compressed_protocol.result
...uite/rpl/r/rpl_semi_sync_slave_compressed_protocol.result
+19
-0
mysql-test/suite/rpl/t/rpl_semi_sync_slave_compressed_protocol-slave.opt
...e/rpl/t/rpl_semi_sync_slave_compressed_protocol-slave.opt
+1
-0
mysql-test/suite/rpl/t/rpl_semi_sync_slave_compressed_protocol.test
.../suite/rpl/t/rpl_semi_sync_slave_compressed_protocol.test
+55
-0
mysql-test/suite/sql_sequence/concurrent_create.result
mysql-test/suite/sql_sequence/concurrent_create.result
+13
-0
mysql-test/suite/sql_sequence/concurrent_create.test
mysql-test/suite/sql_sequence/concurrent_create.test
+19
-0
sql/semisync_master_ack_receiver.cc
sql/semisync_master_ack_receiver.cc
+5
-0
sql/sql_select.cc
sql/sql_select.cc
+10
-1
storage/innobase/row/row0merge.cc
storage/innobase/row/row0merge.cc
+1
-1
support-files/mariadb.service.in
support-files/mariadb.service.in
+1
-1
support-files/mariadb@.service.in
support-files/mariadb@.service.in
+1
-1
No files found.
mysql-test/main/subselect4.result
View file @
90a306a7
...
...
@@ -2786,6 +2786,67 @@ id select_type table type possible_keys key key_len ref rows Extra
set names default;
set @@in_predicate_conversion_threshold= @save_in_predicate_conversion_threshold;
DROP TABLE t1,t2;
#
# MDEV-24925: Server crashes in Item_subselect::init_expr_cache_tracker
#
CREATE TABLE t1 (id INT PRIMARY KEY);
INSERT INTO t1 VALUES (1),(2);
SELECT
1 IN (
SELECT
(SELECT COUNT(id)
FROM t1
WHERE t1_outer.id <> id
) AS f
FROM
t1 AS t1_outer
GROUP BY f
);
1 IN (
SELECT
(SELECT COUNT(id)
FROM t1
WHERE t1_outer.id <> id
) AS f
FROM
t1 AS t1_outer
GROUP BY f
)
1
SELECT
1 IN (
SELECT
(SELECT COUNT(id)
FROM t1
WHERE t1_outer.id <> id
) AS f
FROM
t1 AS t1_outer
GROUP BY 1
);
1 IN (
SELECT
(SELECT COUNT(id)
FROM t1
WHERE t1_outer.id <> id
) AS f
FROM
t1 AS t1_outer
GROUP BY 1
)
1
DROP TABLE t1;
#
# MDEV-24898: Server crashes in st_select_lex::next_select / Item_subselect::is_expensive
# (Testcase)
#
CREATE TABLE t1 (a INT);
INSERT INTO t1 VALUES (1),(2);
CREATE TABLE t2 (b INT);
INSERT INTO t2 VALUES (3),(4);
SELECT 1 IN (SELECT (SELECT a FROM t1) AS x FROM t2 GROUP BY x);
ERROR 21000: Subquery returns more than 1 row
drop table t1,t2;
# End of 10.3 tests
#
# MDEV-19134: EXISTS() slower if ORDER BY is defined
...
...
mysql-test/main/subselect4.test
View file @
90a306a7
...
...
@@ -2308,6 +2308,51 @@ set names default;
set
@@
in_predicate_conversion_threshold
=
@
save_in_predicate_conversion_threshold
;
DROP
TABLE
t1
,
t2
;
--
echo
#
--
echo
# MDEV-24925: Server crashes in Item_subselect::init_expr_cache_tracker
--
echo
#
CREATE
TABLE
t1
(
id
INT
PRIMARY
KEY
);
INSERT
INTO
t1
VALUES
(
1
),(
2
);
SELECT
1
IN
(
SELECT
(
SELECT
COUNT
(
id
)
FROM
t1
WHERE
t1_outer
.
id
<>
id
)
AS
f
FROM
t1
AS
t1_outer
GROUP
BY
f
);
SELECT
1
IN
(
SELECT
(
SELECT
COUNT
(
id
)
FROM
t1
WHERE
t1_outer
.
id
<>
id
)
AS
f
FROM
t1
AS
t1_outer
GROUP
BY
1
);
DROP
TABLE
t1
;
--
echo
#
--
echo
# MDEV-24898: Server crashes in st_select_lex::next_select / Item_subselect::is_expensive
--
echo
# (Testcase)
--
echo
#
CREATE
TABLE
t1
(
a
INT
);
INSERT
INTO
t1
VALUES
(
1
),(
2
);
# Optional, fails either way
CREATE
TABLE
t2
(
b
INT
);
INSERT
INTO
t2
VALUES
(
3
),(
4
);
# Optional, fails either way
--
error
ER_SUBQUERY_NO_1_ROW
SELECT
1
IN
(
SELECT
(
SELECT
a
FROM
t1
)
AS
x
FROM
t2
GROUP
BY
x
);
drop
table
t1
,
t2
;
--
echo
# End of 10.3 tests
--
echo
#
...
...
mysql-test/suite/innodb/r/default_row_format_alter.result
View file @
90a306a7
...
...
@@ -83,6 +83,16 @@ Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length I
t1 InnoDB # Compact # # # # # # NULL # # NULL latin1_swedish_ci NULL 0 N
DROP TABLE t1;
#
# MDEV-24758 heap-use-after-poison in innobase_add_instant_try/rec_copy
#
CREATE TABLE t1 (pk INT PRIMARY KEY) CHARACTER SET utf8 ENGINE=InnoDB;
INSERT INTO t1 VALUES (1);
SET GLOBAL innodb_default_row_format = REDUNDANT;
ALTER TABLE t1 ADD a CHAR(8) DEFAULT '';
DROP TABLE t1;
SET GLOBAL innodb_default_row_format = @row_format;
# End of 10.3 tests
#
# MDEV-23295 Assertion fields[i].same(instant.fields[i]) failed
#
SET GLOBAL innodb_default_row_format = @row_format;
...
...
@@ -104,4 +114,5 @@ SELECT ROW_FORMAT FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME='t1';
ROW_FORMAT
Dynamic
DROP TABLE t1;
# End of 10.4 tests
SET GLOBAL innodb_default_row_format = @row_format;
mysql-test/suite/innodb/t/default_row_format_alter.test
View file @
90a306a7
...
...
@@ -96,6 +96,19 @@ ALTER TABLE t1 DROP INDEX k1;
SHOW
TABLE
STATUS
LIKE
't1'
;
DROP
TABLE
t1
;
--
echo
#
--
echo
# MDEV-24758 heap-use-after-poison in innobase_add_instant_try/rec_copy
--
echo
#
CREATE
TABLE
t1
(
pk
INT
PRIMARY
KEY
)
CHARACTER
SET
utf8
ENGINE
=
InnoDB
;
INSERT
INTO
t1
VALUES
(
1
);
SET
GLOBAL
innodb_default_row_format
=
REDUNDANT
;
ALTER
TABLE
t1
ADD
a
CHAR
(
8
)
DEFAULT
''
;
DROP
TABLE
t1
;
SET
GLOBAL
innodb_default_row_format
=
@
row_format
;
--
echo
# End of 10.3 tests
--
echo
#
--
echo
# MDEV-23295 Assertion fields[i].same(instant.fields[i]) failed
--
echo
#
...
...
@@ -116,4 +129,6 @@ ALTER TABLE t1 DROP b;
SELECT
ROW_FORMAT
FROM
INFORMATION_SCHEMA
.
TABLES
WHERE
TABLE_NAME
=
't1'
;
DROP
TABLE
t1
;
--
echo
# End of 10.4 tests
SET
GLOBAL
innodb_default_row_format
=
@
row_format
;
mysql-test/suite/rpl/r/rpl_semi_sync_slave_compressed_protocol.result
0 → 100644
View file @
90a306a7
include/master-slave.inc
[connection master]
SET @@GLOBAL.rpl_semi_sync_master_enabled = 1;
connection slave;
include/stop_slave.inc
SET @@GLOBAL.rpl_semi_sync_slave_enabled = 1;
include/start_slave.inc
connection master;
CREATE TABLE t1 (i INT);
DROP TABLE t1;
include/rpl_sync.inc
include/assert_grep.inc [Check that there is no 'Read semi-sync reply magic number error' in error log.]
connection master;
SET @@GLOBAL. rpl_semi_sync_master_enabled = $sav_enabled_master;
connection slave;
include/stop_slave.inc
SET @@GLOBAL. rpl_semi_sync_slave_enabled = $sav_enabled_slave;
include/start_slave.inc
include/rpl_end.inc
mysql-test/suite/rpl/t/rpl_semi_sync_slave_compressed_protocol-slave.opt
0 → 100644
View file @
90a306a7
--slave_compressed_protocol
mysql-test/suite/rpl/t/rpl_semi_sync_slave_compressed_protocol.test
0 → 100644
View file @
90a306a7
################################################################################
# Bug#26027024 SLAVE_COMPRESSED_PROTOCOL DOESN'T WORK WITH SEMI-SYNC
# REPLICATION IN MYSQL-5.7
#
# Steps to reproduce:
# 1) Set slave_compressed_protocol ON on Slave.
# 2) Do some sample work on Master
# 3) After the work is synced on Slave, check that there is no error
# (Read semi-sync reply magic number error) on Slave.
# 4) Cleanup
################################################################################
# Test is independent of Binlog format. One of the three formats is enough
# for testing. Choosing 'Row' format.
--
source
include
/
have_binlog_format_row
.
inc
--
source
include
/
master
-
slave
.
inc
--
let
$sav_enabled_master
=
`SELECT @@GLOBAL.rpl_semi_sync_master_enabled `
SET
@@
GLOBAL
.
rpl_semi_sync_master_enabled
=
1
;
--
connection
slave
source
include
/
stop_slave
.
inc
;
--
let
$sav_enabled_slave
=
`SELECT @@GLOBAL.rpl_semi_sync_slave_enabled `
SET
@@
GLOBAL
.
rpl_semi_sync_slave_enabled
=
1
;
source
include
/
start_slave
.
inc
;
--
connection
master
# Do some sample work on Master with slave_compressed_protocol ON.
# (slave_compressed_protocol is set to ON in -slave.opt file of this test.)
CREATE
TABLE
t1
(
i
INT
);
DROP
TABLE
t1
;
# Make sure sync is done, so that next 'assert' step can be executed without
# any issues.
--
source
include
/
rpl_sync
.
inc
# Without the fix, the test would have generated few
# errors in the error log. With the fix, test will
# pass without any errors in the error log.
--
let
$assert_text
=
Check
that
there
is
no
'Read semi-sync reply magic number error'
in
error
log
.
--
let
$assert_select
=
Read
semi
-
sync
reply
magic
number
error
--
let
$assert_file
=
$MYSQLTEST_VARDIR
/
log
/
mysqld
.
1.
err
--
let
$assert_count
=
0
--
let
$assert_only_after
=
CURRENT_TEST
:
rpl
.
rpl_semi_sync_slave_compressed_protocol
.
test
--
source
include
/
assert_grep
.
inc
--
connection
master
--
evalp
SET
@@
GLOBAL
.
rpl_semi_sync_master_enabled
=
$sav_enabled_master
--
connection
slave
source
include
/
stop_slave
.
inc
;
--
evalp
SET
@@
GLOBAL
.
rpl_semi_sync_slave_enabled
=
$sav_enabled_slave
source
include
/
start_slave
.
inc
;
# Cleanup
--
source
include
/
rpl_end
.
inc
mysql-test/suite/sql_sequence/concurrent_create.result
View file @
90a306a7
...
...
@@ -31,3 +31,16 @@ connection con1;
disconnect con1;
connection default;
DROP TABLE s1,s2;
CREATE TABLE t1 (a INT) ENGINE=InnoDB;
START TRANSACTION WITH CONSISTENT SNAPSHOT;
connect con1,localhost,root,,test;
CREATE SEQUENCE s1 ENGINE=InnoDB;
FLUSH TABLES;
disconnect con1;
connection default;
SELECT NEXTVAL(s1);
NEXTVAL(s1)
1
COMMIT;
DROP TABLE t1;
DROP SEQUENCE s1;
mysql-test/suite/sql_sequence/concurrent_create.test
View file @
90a306a7
...
...
@@ -56,3 +56,22 @@ FLUSH TABLES;
--
connection
default
DROP
TABLE
s1
,
s2
;
#
# MDEV-24545 Sequence created by one connection remains invisible to another
#
CREATE
TABLE
t1
(
a
INT
)
ENGINE
=
InnoDB
;
START
TRANSACTION
WITH
CONSISTENT
SNAPSHOT
;
--
connect
(
con1
,
localhost
,
root
,,
test
)
CREATE
SEQUENCE
s1
ENGINE
=
InnoDB
;
FLUSH
TABLES
;
--
disconnect
con1
--
connection
default
SELECT
NEXTVAL
(
s1
);
COMMIT
;
# Cleanup
DROP
TABLE
t1
;
DROP
SEQUENCE
s1
;
sql/semisync_master_ack_receiver.cc
View file @
90a306a7
...
...
@@ -267,6 +267,11 @@ void Ack_receiver::run()
net_clear
(
&
net
,
0
);
net
.
vio
=
&
slave
->
vio
;
/*
Set compress flag. This is needed to support
Slave_compress_protocol flag enabled Slaves
*/
net
.
compress
=
slave
->
thd
->
net
.
compress
;
len
=
my_net_read
(
&
net
);
if
(
likely
(
len
!=
packet_error
))
...
...
sql/sql_select.cc
View file @
90a306a7
...
...
@@ -660,7 +660,16 @@ void remove_redundant_subquery_clauses(st_select_lex *subq_select_lex)
{
for
(
ORDER
*
ord
=
subq_select_lex
->
group_list
.
first
;
ord
;
ord
=
ord
->
next
)
{
(*ord->item)->walk(&Item::eliminate_subselect_processor, FALSE, NULL);
/*
Do not remove the item if it is used in select list and then referred
from GROUP BY clause by its name or number. Example:
select (select ... ) as SUBQ ... group by SUBQ
Here SUBQ cannot be removed.
*/
if
(
!
ord
->
in_field_list
)
(
*
ord
->
item
)
->
walk
(
&
Item
::
eliminate_subselect_processor
,
FALSE
,
NULL
);
}
subq_select_lex
->
join
->
group_list
=
NULL
;
subq_select_lex
->
group_list
.
empty
();
...
...
storage/innobase/row/row0merge.cc
View file @
90a306a7
...
...
@@ -4473,7 +4473,7 @@ row_merge_is_index_usable(
}
return
(
!
index
->
is_corrupted
()
&&
(
index
->
table
->
is_temporary
()
&&
(
index
->
table
->
is_temporary
()
||
index
->
table
->
no_rollback
()
||
index
->
trx_id
==
0
||
!
trx
->
read_view
.
is_open
()
||
trx
->
read_view
.
changes_visible
(
...
...
support-files/mariadb.service.in
View file @
90a306a7
...
...
@@ -145,7 +145,7 @@ TimeoutStopSec=900
##
# Number of files limit. previously [mysqld_safe] open-files-limit
LimitNOFILE=
16384
LimitNOFILE=
32768
# Maximium core size. previously [mysqld_safe] core-file-size
# LimitCore=
...
...
support-files/mariadb@.service.in
View file @
90a306a7
...
...
@@ -268,7 +268,7 @@ Group=mysql
##
# Number of files limit. previously [mysqld_safe] open-files-limit
LimitNOFILE=
16384
LimitNOFILE=
32768
# Maximium core size. previously [mysqld_safe] core-file-size
# LimitCore=
...
...
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