[MDEV-32444] Data from orphaned XA transaction is lost after online alter Created: 2023-10-11  Updated: 2023-11-04  Resolved: 2023-11-04

Status: Closed
Project: MariaDB Server
Component/s: Data Definition - Alter Table, XA
Affects Version/s: 11.2
Fix Version/s: 11.2.2

Type: Bug Priority: Blocker
Reporter: Nikita Malyavin Assignee: Nikita Malyavin
Resolution: Fixed Votes: 0
Labels: regression

Issue Links:
Problem/Incident
is caused by MDEV-16329 Engine-independent online ALTER TABLE Closed

 Description   

--source include/have_innodb.inc
 
create table t (a int primary key) engine=innodb;
insert into t values (1);
 
--echo # XA commit
 
set debug_sync= 'alter_table_online_downgraded signal downgraded wait_for go';
send alter table t force, algorithm=copy, lock=none;
 
--connect(con1, localhost, root,,)
set debug_sync= 'now wait_for downgraded';
xa begin 'x1';
update t set a = 2 where a = 1;
xa end 'x1';
xa prepare 'x1';
--disconnect con1
--connect(con1, localhost, root,,)
xa commit 'x1';
set debug_sync= 'now signal go';
--connection default
--reap # alter table
 
select * from t;

The result expected is 2 in the output, but actual result is 1.


Generated at Thu Feb 08 10:31:24 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.