[MDEV-31921] Replication Breaks after Recovering a Prepared-but-not-binlogged XA ONE PHASE Transaction Created: 2023-08-14 Updated: 2023-11-28 |
|
| Status: | Open |
| Project: | MariaDB Server |
| Component/s: | Replication |
| Affects Version/s: | 10.5, 10.6, 10.7, 10.8, 10.9, 10.10, 10.11, 11.0, 11.1 |
| Fix Version/s: | 10.5, 10.6, 10.11 |
| Type: | Bug | Priority: | Major |
| Reporter: | Brandon Nesterenko | Assignee: | Brandon Nesterenko |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
If the server crashes when executing a ONE PHASE XA transaction after it is prepared in the storage engine, but before it is binlogged, upon recovery, the binlogged transaction is incomplete. That is, only the XA COMMIT part of the transaction is logged, and the body of the XA transaction is lost. Consider the following MTR test which shows that an incomplete binary logging of a one phase XA transaction (only XA COMMIT '1' exists in the binary log when executing SHOW BINARY LOGS), and that replication breaks due to an unknown XID on query.
Output of show binlog events:
And SHOW SLAVE STATUS error output:
|