Skip to content

Commit

Permalink
Merge 10.6 into 10.11
Browse files Browse the repository at this point in the history
  • Loading branch information
dr-m committed Dec 21, 2023
2 parents ea0937d + cf86e07 commit 2b8dc76
Show file tree
Hide file tree
Showing 30 changed files with 205 additions and 233 deletions.
4 changes: 2 additions & 2 deletions include/my_pthread.h
Expand Up @@ -673,10 +673,10 @@ extern void my_mutex_end(void);
by GCC 12.3.0, GCC 13.2.0, or clang 16.0.6
would fail ./mtr main.1st when the stack size is 5 MiB.
The minimum is more than 6 MiB for CMAKE_BUILD_TYPE=RelWithDebInfo and
more than 8 MiB for CMAKE_BUILD_TYPE=Debug.
more than 10 MiB for CMAKE_BUILD_TYPE=Debug.
Let us add some safety margin.
*/
# define DEFAULT_THREAD_STACK (10L<<20)
# define DEFAULT_THREAD_STACK (11L<<20)
# else
# define DEFAULT_THREAD_STACK (292*1024L) /* 299008 */
# endif
Expand Down
3 changes: 2 additions & 1 deletion mysql-test/main/type_timestamp.result
Expand Up @@ -1368,7 +1368,7 @@ t1 CREATE TABLE `t1` (
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
drop table t1;
#
# End of 10.10 tests
# End of 10.5 tests
#
#
# MDEV-32203 Raise notes when an index cannot be used on data type mismatch
Expand Down Expand Up @@ -1489,3 +1489,4 @@ indexed_col not_indexed_col
DROP TABLE t2;
DROP TABLE t1;
SET note_verbosity=DEFAULT;
# End of 10.6 tests
4 changes: 3 additions & 1 deletion mysql-test/main/type_timestamp.test
Expand Up @@ -921,7 +921,7 @@ show create table t1;
drop table t1;

--echo #
--echo # End of 10.10 tests
--echo # End of 10.5 tests
--echo #

--echo #
Expand All @@ -941,3 +941,5 @@ DELIMITER ;$$
--source unusable_keys_joins.inc
DROP TABLE t1;
SET note_verbosity=DEFAULT;

--echo # End of 10.6 tests
1 change: 1 addition & 0 deletions mysql-test/suite/galera/disabled.def
Expand Up @@ -29,3 +29,4 @@ mdev-31285 : MDEV-25089 Assertion `error.len > 0' failed in galera::ReplicatorSM
galera_var_ignore_apply_errors : MENT-1997 galera_var_ignore_apply_errors test freezes
MW-402 : temporarily disabled at the request of Codership
MDEV-22232 : temporarily disabled at the request of Codership
galera_desync_overlapped : MDEV-21538 galera_desync_overlapped MTR failed: Result content mismatch
36 changes: 36 additions & 0 deletions mysql-test/suite/galera/r/MDEV-31272.result
@@ -0,0 +1,36 @@
connection node_2;
connection node_1;
connection node_1;
CREATE TABLE t1 (f1 int primary key, f2 int);
INSERT INTO t1 VALUES (1,0);
BEGIN;
INSERT INTO t1 VALUES (2,4),(1,1);
ERROR 23000: Duplicate entry '1' for key 'PRIMARY'
COMMIT;
Writesets replicated (expect 0)
0
connection node_1;
SELECT * FROM t1;
f1 f2
1 0
connection node_2;
SELECT * FROM t1;
f1 f2
1 0
DROP TABLE t1;
connection node_1;
CREATE TABLE t1 (f1 INTEGER PRIMARY KEY, f2 INTEGER);
INSERT INTO t1 VALUES (1,0);
INSERT INTO t1 VALUES (2,4), (1,1);
ERROR 23000: Duplicate entry '1' for key 'PRIMARY'
Writesets replicated (expect 0)
0
connection node_1;
SELECT * FROM t1;
f1 f2
1 0
connection node_2;
SELECT * FROM t1;
f1 f2
1 0
DROP TABLE t1;
2 changes: 1 addition & 1 deletion mysql-test/suite/galera/t/MDEV-22232.test
Expand Up @@ -28,7 +28,7 @@ SET DEBUG_SYNC = 'create_table_select_before_create SIGNAL may_alter WAIT_FOR bf
--connection node_1
SET DEBUG_SYNC = 'now WAIT_FOR may_alter';
--disable_result_log
--error ER_ERROR_ON_RENAME
--error ER_CANT_DROP_FIELD_OR_KEY
ALTER TABLE t1 DROP FOREIGN KEY b, ALGORITHM=COPY;
--enable_result_log

Expand Down
5 changes: 5 additions & 0 deletions mysql-test/suite/galera/t/MDEV-31272.combinations
@@ -0,0 +1,5 @@
[binlogon]
log-bin
log-slave-updates=ON

[binlogoff]
58 changes: 58 additions & 0 deletions mysql-test/suite/galera/t/MDEV-31272.test
@@ -0,0 +1,58 @@
#
# MDEV-31272: Statement rollback causes empty writeset replication
#

--source include/galera_cluster.inc

#
# Case 1: Multi statement transaction
#
--connection node_1
CREATE TABLE t1 (f1 int primary key, f2 int);
INSERT INTO t1 VALUES (1,0);

--let $replicated_old = `SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_replicated'`

BEGIN;
--error ER_DUP_ENTRY
INSERT INTO t1 VALUES (2,4),(1,1);
COMMIT;

--let $replicated_new = `SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_replicated'`

--disable_query_log
--eval SELECT $replicated_new - $replicated_old AS 'Writesets replicated (expect 0)';
--enable_query_log

--connection node_1
SELECT * FROM t1;
--connection node_2
SELECT * FROM t1;

DROP TABLE t1;


#
# Case 2: autocommit statement
#
--connection node_1
CREATE TABLE t1 (f1 INTEGER PRIMARY KEY, f2 INTEGER);
INSERT INTO t1 VALUES (1,0);

--let $replicated_old = `SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_replicated'`

--error ER_DUP_ENTRY
INSERT INTO t1 VALUES (2,4), (1,1);

--let $replicated_new = `SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_replicated'`

--disable_query_log
--eval SELECT $replicated_new - $replicated_old AS 'Writesets replicated (expect 0)';
--enable_query_log

--connection node_1
SELECT * FROM t1;
--connection node_2
SELECT * FROM t1;

DROP TABLE t1;
3 changes: 0 additions & 3 deletions mysql-test/suite/galera_3nodes/disabled.def
Expand Up @@ -12,9 +12,6 @@

galera_2_cluster : MDEV-32631 galera_2_cluster: before_rollback(): Assertion `0' failed
galera_gtid_2_cluster : MDEV-32633 galera_gtid_2_cluster: Assertion `thd->wsrep_next_trx_id() != (0x7fffffffffffffffLL * 2ULL + 1)'
galera_ipv6_mariabackup : MDEV-24097
galera_ipv6_mariabackup_section : MDEV-24097, MDEV-22195
galera_vote_rejoin_mysqldump : MDEV-24481: galera_3nodes.galera_vote_rejoin_mysqldump MTR failed: mysql_shutdown failed
galera_ssl_reload : MDEV-32778 galera_ssl_reload failed with warning message
galera_ipv6_mariabackup : temporarily disabled at the request of Codership
galera_pc_bootstrap : temporarily disabled at the request of Codership
Expand Down
Expand Up @@ -39,6 +39,9 @@ SELECT VARIABLE_VALUE AS expect_Disconnected FROM INFORMATION_SCHEMA.GLOBAL_STAT
expect_Disconnected
Disconnected
SET SESSION wsrep_on=ON;
SELECT VARIABLE_VALUE AS expect_3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
expect_3
3
SELECT VARIABLE_VALUE AS expect_Primary FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_status';
expect_Primary
Primary
Expand All @@ -49,17 +52,11 @@ t1 CREATE TABLE `t1` (
`f1` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
connection node_2;
SET SESSION wsrep_on=OFF;
SET SESSION wsrep_on=ON;
# restart
SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`f1` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
SELECT COUNT(*) AS expect_0 FROM t1;
expect_0
0
CALL mtr.add_suppression("is inconsistent with group");
connection node_3;
SHOW CREATE TABLE t1;
Expand All @@ -71,13 +68,16 @@ DROP TABLE t1;
CALL mtr.add_suppression("Slave SQL: Error 'Can't DROP 'PRIMARY'; check that column/key exists'");
connection node_1;
connection node_1;
CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
CALL mtr.add_suppression("Slave SQL: Error 'The MariaDB server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
DROP USER sst;
connection node_2;
CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
CALL mtr.add_suppression("Slave SQL: Error 'The MariaDB server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
CALL mtr.add_suppression("Can't open and lock time zone table");
CALL mtr.add_suppression("Can't open and lock privilege tables");
CALL mtr.add_suppression("Info table is not ready to be used");
CALL mtr.add_suppression("Native table .* has the wrong structure");
CALL mtr.add_suppression("Table \'mysql.gtid_slave_pos\' doesn\'t exist");
connection node_2;
# restart
connection node_1;
21 changes: 10 additions & 11 deletions mysql-test/suite/galera_3nodes/t/galera_vote_rejoin_mysqldump.test
Expand Up @@ -59,6 +59,7 @@ SET SESSION wsrep_on=ON;
--let $wait_condition = SELECT VARIABLE_VALUE = 3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
--source include/wait_condition.inc

SELECT VARIABLE_VALUE AS expect_3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
SELECT VARIABLE_VALUE AS expect_Primary FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_status';

# Confirm that the table is now identical throughout
Expand All @@ -67,18 +68,7 @@ SELECT VARIABLE_VALUE AS expect_Primary FROM INFORMATION_SCHEMA.GLOBAL_STATUS WH
SHOW CREATE TABLE t1;

--connection node_2
SET SESSION wsrep_on=OFF;
--let $wait_condition = SELECT VARIABLE_VALUE = 'Primary' FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_status';
--source include/wait_condition.inc
--source include/galera_wait_ready.inc
SET SESSION wsrep_on=ON;

# restart node so we don't fail on WSREP_START_POSITION internal check
--source include/restart_mysqld.inc
--source include/wait_until_connected_again.inc

SHOW CREATE TABLE t1;
SELECT COUNT(*) AS expect_0 FROM t1;
CALL mtr.add_suppression("is inconsistent with group");

--connection node_3
Expand All @@ -89,5 +79,14 @@ CALL mtr.add_suppression("Slave SQL: Error 'Can't DROP 'PRIMARY'; check that col
--connection node_1
--source suite/galera/include/galera_sst_restore.inc

--connection node_2
# restart node so we don't fail on WSREP_START_POSITION internal check
--source include/restart_mysqld.inc
--source include/wait_until_connected_again.inc

--connection node_1
--let $wait_condition = SELECT VARIABLE_VALUE = 3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
--source include/wait_condition.inc

# Restore original auto_increment_offset values.
--source ../galera/include/auto_increment_offset_restore.inc
4 changes: 0 additions & 4 deletions mysql-test/suite/wsrep/disabled.def
Expand Up @@ -11,7 +11,3 @@
##############################################################################


mdev_6832: wsrep_provider is read-only for security reasons
MDEV-23092: wsrep_provider is read-only for security reasons
wsrep_variables_no_provider: wsrep_provider is read-only for security reasons
MDEV-22443: it is no longer allowed enable wsrep_on if wsrep_provider is 'none'
3 changes: 0 additions & 3 deletions mysql-test/suite/wsrep/r/MDEV-22443.result

This file was deleted.

13 changes: 0 additions & 13 deletions mysql-test/suite/wsrep/r/MDEV-23092.result

This file was deleted.

11 changes: 0 additions & 11 deletions mysql-test/suite/wsrep/r/mdev_6832.result

This file was deleted.

44 changes: 0 additions & 44 deletions mysql-test/suite/wsrep/r/wsrep_variables_no_provider.result

This file was deleted.

8 changes: 0 additions & 8 deletions mysql-test/suite/wsrep/t/MDEV-22443.cnf

This file was deleted.

12 changes: 0 additions & 12 deletions mysql-test/suite/wsrep/t/MDEV-22443.test

This file was deleted.

8 changes: 0 additions & 8 deletions mysql-test/suite/wsrep/t/MDEV-23092.cnf

This file was deleted.

22 changes: 0 additions & 22 deletions mysql-test/suite/wsrep/t/MDEV-23092.test

This file was deleted.

0 comments on commit 2b8dc76

Please sign in to comment.