summaryrefslogtreecommitdiff
path: root/mysql-test/suite/galera
diff options
context:
space:
mode:
authorPhilip Stoev <philip.stoev@galeracluster.com>2016-04-04 05:14:13 -0700
committerNirbhay Choubey <nirbhay@mariadb.com>2016-08-21 16:17:08 -0400
commitdda114461ecb3f8ea3448a61b3dad7d059dbdaec (patch)
tree7619a13b9c3d1edf2ec565081f4f79d1057cc63d /mysql-test/suite/galera
parentd45b58263ddf815aa04d4dbc9255ed1081e33bdb (diff)
downloadmariadb-git-dda114461ecb3f8ea3448a61b3dad7d059dbdaec.tar.gz
Galera MTR Tests: Fixed tests to account for GAL-391 , GAL-374
Diffstat (limited to 'mysql-test/suite/galera')
-rw-r--r--mysql-test/suite/galera/r/galera_rsu_wsrep_desync.result7
-rw-r--r--mysql-test/suite/galera/t/galera_rsu_wsrep_desync.test26
2 files changed, 20 insertions, 13 deletions
diff --git a/mysql-test/suite/galera/r/galera_rsu_wsrep_desync.result b/mysql-test/suite/galera/r/galera_rsu_wsrep_desync.result
index 62e327ffdee..08980389392 100644
--- a/mysql-test/suite/galera/r/galera_rsu_wsrep_desync.result
+++ b/mysql-test/suite/galera/r/galera_rsu_wsrep_desync.result
@@ -22,12 +22,11 @@ SET GLOBAL wsrep_desync=0;
Warnings:
Warning 1231 'wsrep_desync' is already OFF.
SET wsrep_OSU_method=RSU;
-SET DEBUG_SYNC = 'alter_table_before_open_tables WAIT_FOR continue';
+SET DEBUG_SYNC = 'alter_table_before_create_table_no_lock WAIT_FOR continue';
ALTER TABLE t1 ADD COLUMN f2 INTEGER;;
-SET GLOBAL wsrep_desync=1;
-ERROR HY000: Operation 'desync' failed for SET GLOBAL wsrep_desync=1
-SET GLOBAL wsrep_desync=0;
+SET GLOBAL wsrep_desync=1;;
SET DEBUG_SYNC= 'now SIGNAL continue';
+SET GLOBAL wsrep_desync=0;
SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
diff --git a/mysql-test/suite/galera/t/galera_rsu_wsrep_desync.test b/mysql-test/suite/galera/t/galera_rsu_wsrep_desync.test
index 36ec8563cbe..dc7ff11a9f5 100644
--- a/mysql-test/suite/galera/t/galera_rsu_wsrep_desync.test
+++ b/mysql-test/suite/galera/t/galera_rsu_wsrep_desync.test
@@ -17,9 +17,11 @@ SET wsrep_OSU_method=RSU;
SET DEBUG_SYNC = 'alter_table_before_open_tables WAIT_FOR continue';
--send ALTER TABLE t1 ADD COLUMN f2 INTEGER;
+
--connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1
---connection node_1a
+--connect node_1b, 127.0.0.1, root, , test, $NODE_MYPORT_1
+--connection node_1a
--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.PROCESSLIST WHERE STATE = 'debug sync point: alter_table_before_open_tables'
--source include/wait_condition.inc
@@ -44,24 +46,32 @@ CREATE TABLE t1 (f1 INTEGER) Engine=InnoDB;
SET GLOBAL wsrep_desync=0;
SET wsrep_OSU_method=RSU;
-SET DEBUG_SYNC = 'alter_table_before_open_tables WAIT_FOR continue';
+SET DEBUG_SYNC = 'alter_table_before_create_table_no_lock WAIT_FOR continue';
--send ALTER TABLE t1 ADD COLUMN f2 INTEGER;
--connection node_1a
---let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.PROCESSLIST WHERE STATE = 'debug sync point: alter_table_before_open_tables'
+--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.PROCESSLIST WHERE STATE = 'debug sync point: alter_table_before_create_table_no_lock'
--source include/wait_condition.inc
-# This transition is currently not allowed
---error ER_CANNOT_USER
-SET GLOBAL wsrep_desync=1;
-SET GLOBAL wsrep_desync=0;
+# wsrep_desync=1 will block
+--send SET GLOBAL wsrep_desync=1;
+
+
+--connection node_1b
+--sleep 2
+--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.PROCESSLIST WHERE STATE = 'exit open_tables()' and INFO = 'SET GLOBAL wsrep_desync=1'
+--source include/wait_condition.inc
SET DEBUG_SYNC= 'now SIGNAL continue';
--connection node_1
--reap
+--connection node_1a
+--reap
+SET GLOBAL wsrep_desync=0;
+
SHOW CREATE TABLE t1;
# Restore old state
@@ -74,5 +84,3 @@ CALL mtr.add_suppression("desync failed");
--connection node_2
CALL mtr.add_suppression("Protocol violation");
-
-