summaryrefslogtreecommitdiffstats
path: root/mysql-test/suite/galera_sr
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 13:39:13 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 13:39:13 +0000
commit86fbb58c3ac0865482819c10a3e81f2eea001c36 (patch)
tree28c9e526ea739c6f9b89e36115e1e2698bddf981 /mysql-test/suite/galera_sr
parentReleasing progress-linux version 1:10.11.6-2~progress7.99u1. (diff)
downloadmariadb-86fbb58c3ac0865482819c10a3e81f2eea001c36.tar.xz
mariadb-86fbb58c3ac0865482819c10a3e81f2eea001c36.zip
Merging upstream version 1:10.11.7.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mysql-test/suite/galera_sr')
-rw-r--r--mysql-test/suite/galera_sr/disabled.def4
-rw-r--r--mysql-test/suite/galera_sr/r/MDEV-27615.result2
-rw-r--r--mysql-test/suite/galera_sr/r/MDEV-28971.result17
-rw-r--r--mysql-test/suite/galera_sr/r/galera_sr_cc_master.result30
-rw-r--r--mysql-test/suite/galera_sr/r/mysql-wsrep-features#165.result16
-rw-r--r--mysql-test/suite/galera_sr/t/MDEV-27615.test3
-rw-r--r--mysql-test/suite/galera_sr/t/MDEV-28971.test20
-rw-r--r--mysql-test/suite/galera_sr/t/galera_sr_cc_master.test26
-rw-r--r--mysql-test/suite/galera_sr/t/galera_sr_large_fragment.test3
-rw-r--r--mysql-test/suite/galera_sr/t/galera_sr_many_fragments.test4
-rw-r--r--mysql-test/suite/galera_sr/t/mysql-wsrep-features#165.inc6
11 files changed, 104 insertions, 27 deletions
diff --git a/mysql-test/suite/galera_sr/disabled.def b/mysql-test/suite/galera_sr/disabled.def
index 9cca05eb..73ef1d0d 100644
--- a/mysql-test/suite/galera_sr/disabled.def
+++ b/mysql-test/suite/galera_sr/disabled.def
@@ -10,8 +10,6 @@
#
##############################################################################
-GCF-1060 : MDEV-26528 wrong usage of mutex LOCK_thd_kill and LOCK_thd_kill
-galera_sr_cc_master : MDEV-29882 Galera test failure on galera_sr_cc_master
-mysql-wsrep-features#138 : At line 25: query 'DROP TABLE t1' failed: 2013: Lost connection to MySQL server during query
+GCF-1060 : MDEV-32160 GCF-1060 test failure due to wsrep MDL conflict
# Links to below failures in MDEV-30172
MDEV-25718 : timeout related to wsrep_sync_wait and DEBUG_SYNC
diff --git a/mysql-test/suite/galera_sr/r/MDEV-27615.result b/mysql-test/suite/galera_sr/r/MDEV-27615.result
index e3bfd0ed..8965cc8e 100644
--- a/mysql-test/suite/galera_sr/r/MDEV-27615.result
+++ b/mysql-test/suite/galera_sr/r/MDEV-27615.result
@@ -15,7 +15,7 @@ SET DEBUG_SYNC='now WAIT_FOR before_fragment';
SET GLOBAL wsrep_cluster_address = '';
SET DEBUG_SYNC = 'now SIGNAL continue';
connection node_2;
-ERROR HY000: Lost connection to server during query
+Got one of the listed errors
connection node_2a;
SELECT * FROM mysql.wsrep_streaming_log;
node_uuid trx_id seqno flags frag
diff --git a/mysql-test/suite/galera_sr/r/MDEV-28971.result b/mysql-test/suite/galera_sr/r/MDEV-28971.result
new file mode 100644
index 00000000..0826f5e6
--- /dev/null
+++ b/mysql-test/suite/galera_sr/r/MDEV-28971.result
@@ -0,0 +1,17 @@
+connection node_2;
+connection node_1;
+CREATE SEQUENCE SEQ NOCACHE ENGINE=InnoDB;
+SET SESSION wsrep_trx_fragment_size=1;
+SET collation_connection=utf16_thai_520_w2;
+SET autocommit=0;
+CREATE TABLE t1 (a BLOB UNIQUE);
+INSERT INTO t1 VALUES ('AAF');
+SELECT SETVAL (SEQ, 100);
+ERROR 42000: This version of MariaDB doesn't yet support 'SEQUENCEs with streaming replication in Galera cluster'
+ALTER TABLE t1 ADD CONSTRAINT constraint_1 UNIQUE (a);
+Warnings:
+Note 1831 Duplicate index `constraint_1`. This is deprecated and will be disallowed in a future release
+INSERT INTO t1 VALUES();
+ALTER TABLE t1 ADD KEY(b (50));
+ERROR 42000: Key column 'b' doesn't exist in table
+DROP TABLE t1,SEQ;
diff --git a/mysql-test/suite/galera_sr/r/galera_sr_cc_master.result b/mysql-test/suite/galera_sr/r/galera_sr_cc_master.result
index 1f874aca..19466715 100644
--- a/mysql-test/suite/galera_sr/r/galera_sr_cc_master.result
+++ b/mysql-test/suite/galera_sr/r/galera_sr_cc_master.result
@@ -13,12 +13,12 @@ INSERT INTO t1 VALUES (2);
INSERT INTO t1 VALUES (3);
INSERT INTO t1 VALUES (4);
INSERT INTO t1 VALUES (5);
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
-COUNT(*)
+SELECT COUNT(*) AS EXPECT_5 FROM mysql.wsrep_streaming_log;
+EXPECT_5
5
connection node_1;
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
-COUNT(*)
+SELECT COUNT(*) AS EXPECT_5 FROM mysql.wsrep_streaming_log;
+EXPECT_5
5
connect node_2a, 127.0.0.1, root, , test, $NODE_MYPORT_2;
connection node_2a;
@@ -29,8 +29,8 @@ connection node_2;
INSERT INTO t1 VALUES (6);
ERROR HY000: Lost connection to server during query
connection node_1;
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
-COUNT(*)
+SELECT COUNT(*) AS EXPECT_0 FROM mysql.wsrep_streaming_log;
+EXPECT_0
0
connection node_2a;
connection node_1;
@@ -38,8 +38,8 @@ connect node_2b, 127.0.0.1, root, , test, $NODE_MYPORT_2;
connection node_2b;
SELECT * FROM mysql.wsrep_streaming_log;
node_uuid trx_id seqno flags frag
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
-COUNT(*)
+SELECT COUNT(*) AS EXPECT_0 FROM mysql.wsrep_streaming_log;
+EXPECT_0
0
SET AUTOCOMMIT=OFF;
START TRANSACTION;
@@ -49,18 +49,20 @@ INSERT INTO t1 VALUES (3);
INSERT INTO t1 VALUES (4);
INSERT INTO t1 VALUES (5);
COMMIT;
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
-COUNT(*)
+SELECT COUNT(*) AS EXPECT_0 FROM mysql.wsrep_streaming_log;
+EXPECT_0
0
connection node_1;
-SELECT COUNT(*) FROM t1;
-COUNT(*)
+SELECT COUNT(*) AS EXPECT_5 FROM t1;
+EXPECT_5
5
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
-COUNT(*)
+SELECT COUNT(*) AS EXPECT_0 FROM mysql.wsrep_streaming_log;
+EXPECT_0
0
DROP TABLE t1;
connection node_2b;
CALL mtr.add_suppression("WSREP: Failed to replicate rollback fragment for");
disconnect node_2;
connect node_2, 127.0.0.1, root, , test, $NODE_MYPORT_2;
+disconnect node_2a;
+disconnect node_2b;
diff --git a/mysql-test/suite/galera_sr/r/mysql-wsrep-features#165.result b/mysql-test/suite/galera_sr/r/mysql-wsrep-features#165.result
index 8ad3ac63..353315d1 100644
--- a/mysql-test/suite/galera_sr/r/mysql-wsrep-features#165.result
+++ b/mysql-test/suite/galera_sr/r/mysql-wsrep-features#165.result
@@ -26,6 +26,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -91,6 +92,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -156,6 +158,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -221,6 +224,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -286,6 +290,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -351,6 +356,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -416,6 +422,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -481,6 +488,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -546,6 +554,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -611,6 +620,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -676,6 +686,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -741,6 +752,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -806,6 +818,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -871,6 +884,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -936,6 +950,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
@@ -1001,6 +1016,7 @@ f1 f2
connection node_1c;
SET AUTOCOMMIT=ON;
INSERT INTO t1 VALUES (3, 'c');
+connection node_1;
connection node_2;
SELECT * FROM t1;
f1 f2
diff --git a/mysql-test/suite/galera_sr/t/MDEV-27615.test b/mysql-test/suite/galera_sr/t/MDEV-27615.test
index 121a85fb..8cc425aa 100644
--- a/mysql-test/suite/galera_sr/t/MDEV-27615.test
+++ b/mysql-test/suite/galera_sr/t/MDEV-27615.test
@@ -43,7 +43,8 @@ SET DEBUG_SYNC = 'now SIGNAL continue';
# Disconnect causes connection to node_2 to be closed
#
--connection node_2
---error 2013 # CR_SERVER_LOST
+# CR_SERVER_LOST, CR_SSL_CONNECTION_ERROR
+--error 2013,2026
--reap
diff --git a/mysql-test/suite/galera_sr/t/MDEV-28971.test b/mysql-test/suite/galera_sr/t/MDEV-28971.test
new file mode 100644
index 00000000..d3dbf03b
--- /dev/null
+++ b/mysql-test/suite/galera_sr/t/MDEV-28971.test
@@ -0,0 +1,20 @@
+#
+# MDEV-28971 - Assertion `total_length + thd->wsrep_sr().log_position() == saved_pos'
+# failed in int wsrep_write_cache_inc(THD*, IO_CACHE*, size_t*)
+#
+
+--source include/galera_cluster.inc
+
+CREATE SEQUENCE SEQ NOCACHE ENGINE=InnoDB;
+SET SESSION wsrep_trx_fragment_size=1;
+SET collation_connection=utf16_thai_520_w2;
+SET autocommit=0;
+CREATE TABLE t1 (a BLOB UNIQUE);
+INSERT INTO t1 VALUES ('AAF');
+--error ER_NOT_SUPPORTED_YET
+SELECT SETVAL (SEQ, 100);
+ALTER TABLE t1 ADD CONSTRAINT constraint_1 UNIQUE (a);
+INSERT INTO t1 VALUES();
+--error ER_KEY_COLUMN_DOES_NOT_EXIST
+ALTER TABLE t1 ADD KEY(b (50));
+DROP TABLE t1,SEQ;
diff --git a/mysql-test/suite/galera_sr/t/galera_sr_cc_master.test b/mysql-test/suite/galera_sr/t/galera_sr_cc_master.test
index 6665a6e7..a019a32e 100644
--- a/mysql-test/suite/galera_sr/t/galera_sr_cc_master.test
+++ b/mysql-test/suite/galera_sr/t/galera_sr_cc_master.test
@@ -32,10 +32,13 @@ INSERT INTO t1 VALUES (3);
INSERT INTO t1 VALUES (4);
INSERT INTO t1 VALUES (5);
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
+SELECT COUNT(*) AS EXPECT_5 FROM mysql.wsrep_streaming_log;
--connection node_1
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
+--let $wait_condition = SELECT COUNT(*) = 5 FROM mysql.wsrep_streaming_log
+--source include/wait_condition.inc
+
+SELECT COUNT(*) AS EXPECT_5 FROM mysql.wsrep_streaming_log;
#
# Trigger CC . The transaction is aborted and we expect the SR tables to be cleaned up
@@ -56,7 +59,9 @@ SET SESSION wsrep_sync_wait = DEFAULT;
INSERT INTO t1 VALUES (6);
--connection node_1
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
+--let $wait_condition = SELECT COUNT(*) = 0 FROM mysql.wsrep_streaming_log
+--source include/wait_condition.inc
+SELECT COUNT(*) AS EXPECT_0 FROM mysql.wsrep_streaming_log;
# Restore cluster
@@ -73,8 +78,10 @@ SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
--connect node_2b, 127.0.0.1, root, , test, $NODE_MYPORT_2
--connection node_2b
--source include/galera_wait_ready.inc
+--let $wait_condition = SELECT COUNT(*) = 0 FROM mysql.wsrep_streaming_log
+--source include/wait_condition.inc
SELECT * FROM mysql.wsrep_streaming_log;
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
+SELECT COUNT(*) AS EXPECT_0 FROM mysql.wsrep_streaming_log;
# Repeat transaction to confirm no locks are left from previous transaction
@@ -87,11 +94,13 @@ INSERT INTO t1 VALUES (4);
INSERT INTO t1 VALUES (5);
COMMIT;
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
+SELECT COUNT(*) AS EXPECT_0 FROM mysql.wsrep_streaming_log;
--connection node_1
-SELECT COUNT(*) FROM t1;
-SELECT COUNT(*) FROM mysql.wsrep_streaming_log;
+--let $wait_condition = SELECT COUNT(*) = 5 FROM t1
+--source include/wait_condition.inc
+SELECT COUNT(*) AS EXPECT_5 FROM t1;
+SELECT COUNT(*) AS EXPECT_0 FROM mysql.wsrep_streaming_log;
DROP TABLE t1;
@@ -102,3 +111,6 @@ CALL mtr.add_suppression("WSREP: Failed to replicate rollback fragment for");
--connect node_2, 127.0.0.1, root, , test, $NODE_MYPORT_2
# Restore original auto_increment_offset values.
--source ../galera/include/auto_increment_offset_restore.inc
+
+--disconnect node_2a
+--disconnect node_2b
diff --git a/mysql-test/suite/galera_sr/t/galera_sr_large_fragment.test b/mysql-test/suite/galera_sr/t/galera_sr_large_fragment.test
index 63278555..d08cab49 100644
--- a/mysql-test/suite/galera_sr/t/galera_sr_large_fragment.test
+++ b/mysql-test/suite/galera_sr/t/galera_sr_large_fragment.test
@@ -6,6 +6,8 @@
--source include/have_innodb.inc
--source include/big_test.inc
+--disable_ps2_protocol
+
CREATE TABLE ten (f1 INTEGER) ENGINE=InnoDB;
INSERT INTO ten VALUES (1), (2), (3), (4), (5), (6), (7), (8), (9), (10);
@@ -56,3 +58,4 @@ CALL mtr.add_suppression('InnoDB: Resizing redo log from');
CALL mtr.add_suppression('InnoDB: Starting to delete and rewrite log files');
CALL mtr.add_suppression('InnoDB: New log files created, LSN=');
+--enable_ps2_protocol
diff --git a/mysql-test/suite/galera_sr/t/galera_sr_many_fragments.test b/mysql-test/suite/galera_sr/t/galera_sr_many_fragments.test
index 9b8dae9d..7a6c1bea 100644
--- a/mysql-test/suite/galera_sr/t/galera_sr_many_fragments.test
+++ b/mysql-test/suite/galera_sr/t/galera_sr_many_fragments.test
@@ -6,6 +6,8 @@
--source include/have_innodb.inc
--source include/big_test.inc
+--disable_ps2_protocol
+
CREATE TABLE ten (f1 INTEGER) ENGINE=InnoDB;
INSERT INTO ten VALUES (1), (2), (3), (4), (5), (6), (7), (8), (9), (10);
@@ -51,3 +53,5 @@ SELECT COUNT(*) = 0 FROM t1;
DROP TABLE ten;
DROP TABLE t1;
+
+--enable_ps2_protocol
diff --git a/mysql-test/suite/galera_sr/t/mysql-wsrep-features#165.inc b/mysql-test/suite/galera_sr/t/mysql-wsrep-features#165.inc
index 7f13afa3..26cdd116 100644
--- a/mysql-test/suite/galera_sr/t/mysql-wsrep-features#165.inc
+++ b/mysql-test/suite/galera_sr/t/mysql-wsrep-features#165.inc
@@ -46,6 +46,10 @@ SELECT * FROM t1;
SET AUTOCOMMIT=ON;
--send INSERT INTO t1 VALUES (3, 'c')
+--connection node_1
+--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.INNODB_LOCK_WAITS;
+--source include/wait_condition.inc
+
--connection node_2
SELECT * FROM t1;
@@ -54,7 +58,7 @@ SELECT * FROM t1;
--send UPDATE t1 SET f2 = 'a' WHERE f1 = 2
--connection node_1
---let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.PROCESSLIST WHERE USER != 'system user' AND STATE = 'Updating';
+--let $wait_condition = SELECT COUNT(*) = 2 FROM INFORMATION_SCHEMA.INNODB_LOCK_WAITS;
--source include/wait_condition.inc
# Will deadlock