[MDEV-32455] Implicit rollback by LOAD INDEX or CACHE INDEX should not touch prepared user XA Created: 2023-10-12  Updated: 2024-01-08

Status: Confirmed
Project: MariaDB Server
Component/s: Server, XA
Affects Version/s: 10.4, 10.5, 10.6, 10.9, 10.10, 10.11, 11.0, 11.1, 11.2, 11.3
Fix Version/s: 10.4, 10.5, 10.6, 10.11, 11.0, 11.1, 11.2

Type: Bug Priority: Major
Reporter: Andrei Elkin Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: corruption

Issue Links:
Relates
relates to MDEV-31949 slow parallel replication of user xa In Review
relates to MDEV-32347 Stack smashing/looping, ASAN use-afte... Closed

 Description   

Elaborated MDEV-32347 description test demonstrates how a prepared user XA transaction
gets rolled back:

CREATE TABLE ti (c INT KEY) engine=Innodb;
XA START 'xid_i';
INSERT INTO ti VALUES (1);
XA END 'xid_i';
XA PREPARE 'xid_i';
 
# --error ER_XAER_RMFAIL
LOAD INDEX INTO CACHE c KEY(PRIMARY);
 
XA COMMIT 'xid_i';
 
SELECT count(*) = 1 FROM ti;
# => 0 (sic!)

LOAD INDEX INTO CACHE and CACHE INDEX ... must also error out which is not done (by at least LOAD INDEX) either.

No other sql commands, form either DML:s or DDL:s class, are found to produce similar effect.


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