summaryrefslogtreecommitdiff
path: root/mysql-test/suite/galera_sr/t/MDEV-27553.test
blob: d17af175512af753e9e57ef097faa308310dd0d8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#
# MDEV-27553 Assertion `inited==INDEX' failed: int handler::ha_index_end()
#

--source include/galera_cluster.inc
--source include/have_debug.inc

CREATE TABLE t1 (f1 INTEGER PRIMARY KEY);

--connection node_1
--let $wsrep_cluster_address_orig = `SELECT @@wsrep_cluster_address`
SET SESSION wsrep_trx_fragment_size=1;
START TRANSACTION;
INSERT INTO t1 VALUES (1);
# This will result in failure to remove fragments
# from streaming log, in the following ROLLBACK.
SET @@global.debug_dbug="+d,ha_index_init_fail";
ROLLBACK;

--connection node_2
SELECT COUNT(*) `Expect 0` FROM mysql.wsrep_streaming_log;


--connection node_1
SET @@global.debug_dbug="";
SELECT COUNT(*) `Expect 1` FROM mysql.wsrep_streaming_log;

SET SESSION wsrep_on=OFF;
DELETE FROM mysql.wsrep_streaming_log;
SET SESSION wsrep_on=ON;
DROP TABLE t1;

CALL mtr.add_suppression("WSREP: Failed to init table for index scan");