diff options
author | Kentoku SHIBA <kentokushiba@gmail.com> | 2019-04-12 22:47:29 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-12 22:47:29 +0900 |
commit | df2d376eca665e26845d8e6c636bf9f6c1714b1b (patch) | |
tree | 77472ce6fdb212e7cadb9fe1ccd351bab193797a /mysql-test/suite/galera/t | |
parent | f0509afa1b635cd7c091f349a3b8dd72b4b92b94 (diff) | |
parent | 7896503686477cce55d058d071d2858a8abf4b04 (diff) | |
download | mariadb-git-bb-10.4-MDEV-16530.tar.gz |
Merge branch '10.4' into bb-10.4-MDEV-16530bb-10.4-MDEV-16530
Diffstat (limited to 'mysql-test/suite/galera/t')
-rw-r--r-- | mysql-test/suite/galera/t/GCF-1081.test | 4 | ||||
-rw-r--r-- | mysql-test/suite/galera/t/galera_sp_insert_parallel.test | 55 |
2 files changed, 57 insertions, 2 deletions
diff --git a/mysql-test/suite/galera/t/GCF-1081.test b/mysql-test/suite/galera/t/GCF-1081.test index 8296c55f1b6..38553feda39 100644 --- a/mysql-test/suite/galera/t/GCF-1081.test +++ b/mysql-test/suite/galera/t/GCF-1081.test @@ -38,7 +38,7 @@ SET SESSION wsrep_sync_wait = 0; # Issue a conflicting insert on node #2 --connection node_1a -SET GLOBAL DEBUG = 'd,sync.wsrep_before_BF_victim_unlock'; +SET GLOBAL debug_dbug = 'd,sync.wsrep_before_BF_victim_unlock'; --connection node_2 --send INSERT INTO t1 VALUES (2, 2); @@ -46,7 +46,7 @@ SET GLOBAL DEBUG = 'd,sync.wsrep_before_BF_victim_unlock'; # Wait until it BF aborts the SP --connection node_1a SET SESSION DEBUG_SYNC = 'now WAIT_FOR sync.wsrep_before_BF_victim_unlock_reached'; -SET GLOBAL DEBUG = ''; +SET GLOBAL debug_dbug = ''; # Unblock the SP --connection node_1a diff --git a/mysql-test/suite/galera/t/galera_sp_insert_parallel.test b/mysql-test/suite/galera/t/galera_sp_insert_parallel.test new file mode 100644 index 00000000000..b6878a9c32a --- /dev/null +++ b/mysql-test/suite/galera/t/galera_sp_insert_parallel.test @@ -0,0 +1,55 @@ +--source include/galera_cluster.inc +--source include/have_innodb.inc + +CREATE TABLE t1 (f1 INTEGER PRIMARY KEY, f2 INTEGER) ENGINE=InnoDB; + + +DELIMITER |; +CREATE PROCEDURE proc_insert() +BEGIN + DECLARE i INT; + DECLARE CONTINUE HANDLER FOR SQLEXCEPTION BEGIN END; + + SET i = 0; + WHILE i < 1000 DO + INSERT IGNORE INTO t1 (f1, f2) + VALUES (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)), + (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)), + (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)), + (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)), + (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)), + (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)), + (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)), + (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)), + (FLOOR(1 + RAND() * 65535), FLOOR(1 + RAND() * 15)); + SET i = i + 1; + + END WHILE; +END| +DELIMITER ;| + +--connection node_1 +SELECT 0; +SET SESSION wsrep_sync_wait = 0; +--send CALL proc_insert +--connection node_2 +SELECT 0; +SET SESSION wsrep_sync_wait = 0; +--send CALL proc_insert + +--connection node_1 +--error 0,ER_LOCK_DEADLOCK,ER_QUERY_INTERRUPTED +--disable_warnings +--reap +--enable_warnings +SET SESSION wsrep_sync_wait = default; +--connection node_2 +--error 0,ER_LOCK_DEADLOCK,ER_QUERY_INTERRUPTED +--disable_warnings +--reap +--enable_warnings +SET SESSION wsrep_sync_wait = default; + +--connection node_1 +DROP PROCEDURE proc_insert; +DROP TABLE t1; |