summaryrefslogtreecommitdiffstats
path: root/mysql-test/suite/galera/t/MDEV-22051.test
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--mysql-test/suite/galera/t/MDEV-22051.test34
1 files changed, 34 insertions, 0 deletions
diff --git a/mysql-test/suite/galera/t/MDEV-22051.test b/mysql-test/suite/galera/t/MDEV-22051.test
new file mode 100644
index 00000000..a5f05f5c
--- /dev/null
+++ b/mysql-test/suite/galera/t/MDEV-22051.test
@@ -0,0 +1,34 @@
+#
+# If FTWRL is issued on node, DDL statement should report error back to
+# user.
+#
+
+--source include/galera_cluster.inc
+--source include/have_innodb.inc
+
+FLUSH TABLES WITH READ LOCK;
+
+--error ER_UNKNOWN_COM_ERROR
+CREATE TABLE t1 (a INT) ENGINE=InnoDB;
+
+SET wsrep_OSU_method=RSU;
+--error ER_UNKNOWN_COM_ERROR
+CREATE TABLE t1 (a INT) ENGINE=InnoDB;
+SET wsrep_OSU_method=TOI;
+
+--connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1
+--error ER_UNKNOWN_COM_ERROR
+CREATE TABLE t1 (a INT) ENGINE=InnoDB;
+
+--connection node_1
+UNLOCK TABLES;
+
+CREATE TABLE t1 (a INT) ENGINE=InnoDB;
+
+FLUSH TABLES WITH READ LOCK;
+--error ER_CANT_UPDATE_WITH_READLOCK
+INSERT INTO t1 VALUES (1);
+UNLOCK TABLES;
+
+DROP TABLE t1;
+CALL mtr.add_suppression("CREATE TABLE isolation failure");