[MDEV-27363] Using different GTID_DOMAIN_ID than 0 still causes stuck replication if pending queries > slave_parallel_threads Created: 2021-12-25  Updated: 2021-12-25

Status: Open
Project: MariaDB Server
Component/s: None
Affects Version/s: 10.6.4
Fix Version/s: None

Type: Bug Priority: Minor
Reporter: Himanshu Mishra Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None


 Description   

If we execute multiple transactions on primary with a GTID_DOMAIN_ID other than 0 still causes a replication block if more queries completed on primary than there are slave_parallel_threads.

Let's say we have 3 parallel threads.

Let's say we execute
1. set session GTID_DOMAIN_ID=4; alter table x row_format=dynamic;
2. set session GTID_DOMAIN_ID=4; alter table y row_format=dynamic;
3. set session GTID_DOMAIN_ID=4; alter table z row_format=dynamic;

If all three of them complete on primary, while replica is still executing statement 1, other two threads will still stay blocked with message `Waiting for prior transaction to start commit`.

This causes GTID_DOMAIN_ID=0 to not be scheduled on workers and lag starts increasing till all the transactions finish.


Generated at Thu Feb 08 09:52:21 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.