server
server copied to clipboard
MDEV-35217: Provide information for debugging parallel replication
Implement an option --slave-parallel-print-all-deadlocks to debug parallel replication conflicts. This option enables additional information in the server's error log when a parallel replication conflict or deadlock occurs, similar to --innodb-print-all-deadlocks. This should be very useful to help investigate the cause of problems with parallel replication, including helping to find the root cause of any bugs.
The information printed includes the GTID and thread info of conflicting threads; the chain of wait_for_prior_commits; and the SHOW ENGINE STATUS of engines participating in the current transaction.
Setting @@slave_parallel_print_all_deadlocks to 1 will output the information when an unexpected conflict occurs; this means an event group that needed to retry more than once, or any lock wait timeout. Setting @@slave_parallel_print_all_deadlocks to 2 will output the information for any detected conflict.
- [x] The Jira issue number for this PR is: MDEV-______
Description
TODO: fill description here
Release Notes
TODO: What should the release notes say about this change? Include any changed system variables, status variables or behaviour. Optionally list any https://mariadb.com/kb/ pages that need changing.
How can this PR be tested?
TODO: modify the automated test suite to verify that the PR causes MariaDB to behave as intended. Consult the documentation on "Writing good test cases".
If the changes are not amenable to automated testing, please explain why not and carefully describe how to test manually.
Basing the PR against the correct MariaDB version
- [ ] This is a new feature or a refactoring, and the PR is based against the
mainbranch. - [ ] This is a bug fix, and the PR is based against the earliest maintained branch in which the bug can be reproduced.
PR quality check
- [ ] I checked the CODING_STANDARDS.md file and my PR conforms to this where appropriate.
- [ ] For any trivial modifications to the PR, I am ok with the reviewer making the changes themselves.