Type:
Bug
Priority:
Critical
Resolution:
Fixed
Affects Version/s:
None
When a galera node is a replica of an upstream cluster it is impossible to enable optimistic replication, because the expected conflicts that stem from this replication mode will cause galera code to immediately abort replication.
2023-05-17 13:57:20 6930586 [Note] WSREP: ha_rollback_trans(6930586) rolled back: Deadlock found when trying to get lock; try restarting transaction; is_real 0
2023-05-17 13:57:20 6930586 [Note] WSREP: ha_rollback_trans(6930586) rolled back: Deadlock found when trying to get lock; try restarting transaction; is_real 1
2023-05-17 13:57:20 6930586 [Note] WSREP: SQL apply failed, res 149 conflict state: aborted
2023-05-17 13:57:20 6930586 [ERROR] Slave SQL: Node has dropped from cluster, Gtid 0-8174-126467367555, Internal MariaDB error code: 1047
relates to
MDEV-10962
Deadlock with 3 concurrent DELETEs by unique key
Closed
{"report":{"fcp":711,"ttfb":180.40000000596046,"pageVisibility":"visible","entityId":121931,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"4132b134-6db5-4baf-92a5-dfbf04bcd574","navigationType":0,"readyForUser":784.5999999940395,"redirectCount":0,"resourceLoadedEnd":957.3000000119209,"resourceLoadedStart":186,"resourceTiming":[{"duration":9.200000017881393,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":186,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":186,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":195.2000000178814,"responseStart":0,"secureConnectionStart":0},{"duration":9.199999988079071,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":186.30000001192093,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":186.30000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":195.5,"responseStart":0,"secureConnectionStart":0},{"duration":63.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/fbf975c0cce4b1abf04784eeae9ba1f4-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":186.40000000596046,"connectEnd":186.40000000596046,"connectStart":186.40000000596046,"domainLookupEnd":186.40000000596046,"domainLookupStart":186.40000000596046,"fetchStart":186.40000000596046,"redirectEnd":0,"redirectStart":0,"requestStart":186.40000000596046,"responseEnd":249.90000000596046,"responseStart":249.90000000596046,"secureConnectionStart":186.40000000596046},{"duration":150.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/099b33461394b8015fc36c0a4b96e19f-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true","startTime":186.59999999403954,"connectEnd":186.59999999403954,"connectStart":186.59999999403954,"domainLookupEnd":186.59999999403954,"domainLookupStart":186.59999999403954,"fetchStart":186.59999999403954,"redirectEnd":0,"redirectStart":0,"requestStart":186.59999999403954,"responseEnd":337.09999999403954,"responseStart":337.09999999403954,"secureConnectionStart":186.59999999403954},{"duration":153.90000000596046,"initiatorType":"script","name":"https://jira.mariadb.org/s/94c15bff32baef80f4096a08aceae8bc-CDN/lu2bu7/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":186.80000001192093,"connectEnd":186.80000001192093,"connectStart":186.80000001192093,"domainLookupEnd":186.80000001192093,"domainLookupStart":186.80000001192093,"fetchStart":186.80000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":186.80000001192093,"responseEnd":340.7000000178814,"responseStart":340.7000000178814,"secureConnectionStart":186.80000001192093},{"duration":154.30000001192093,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":187,"connectEnd":187,"connectStart":187,"domainLookupEnd":187,"domainLookupStart":187,"fetchStart":187,"redirectEnd":0,"redirectStart":0,"requestStart":187,"responseEnd":341.30000001192093,"responseStart":341.30000001192093,"secureConnectionStart":187},{"duration":154.2999999821186,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":187.30000001192093,"connectEnd":187.30000001192093,"connectStart":187.30000001192093,"domainLookupEnd":187.30000001192093,"domainLookupStart":187.30000001192093,"fetchStart":187.30000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":187.30000001192093,"responseEnd":341.59999999403954,"responseStart":341.59999999403954,"secureConnectionStart":187.30000001192093},{"duration":203.59999999403954,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2bu7/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":187.40000000596046,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":187.40000000596046,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":391,"responseStart":0,"secureConnectionStart":0},{"duration":154.60000002384186,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":187.59999999403954,"connectEnd":187.59999999403954,"connectStart":187.59999999403954,"domainLookupEnd":187.59999999403954,"domainLookupStart":187.59999999403954,"fetchStart":187.59999999403954,"redirectEnd":0,"redirectStart":0,"requestStart":187.59999999403954,"responseEnd":342.2000000178814,"responseStart":342.2000000178814,"secureConnectionStart":187.59999999403954},{"duration":203.39999997615814,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2bu7/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":187.7000000178814,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":187.7000000178814,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":391.09999999403954,"responseStart":0,"secureConnectionStart":0},{"duration":155,"initiatorType":"script","name":"https://jira.mariadb.org/s/3339d87fa2538a859872f2df449bf8d0-CDN/lu2bu7/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":187.90000000596046,"connectEnd":187.90000000596046,"connectStart":187.90000000596046,"domainLookupEnd":187.90000000596046,"domainLookupStart":187.90000000596046,"fetchStart":187.90000000596046,"redirectEnd":0,"redirectStart":0,"requestStart":187.90000000596046,"responseEnd":342.90000000596046,"responseStart":342.90000000596046,"secureConnectionStart":187.90000000596046},{"duration":750,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":188.7000000178814,"connectEnd":188.7000000178814,"connectStart":188.7000000178814,"domainLookupEnd":188.7000000178814,"domainLookupStart":188.7000000178814,"fetchStart":188.7000000178814,"redirectEnd":0,"redirectStart":0,"requestStart":188.7000000178814,"responseEnd":938.7000000178814,"responseStart":938.7000000178814,"secureConnectionStart":188.7000000178814},{"duration":752,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":188.80000001192093,"connectEnd":188.80000001192093,"connectStart":188.80000001192093,"domainLookupEnd":188.80000001192093,"domainLookupStart":188.80000001192093,"fetchStart":188.80000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":188.80000001192093,"responseEnd":940.8000000119209,"responseStart":940.8000000119209,"secureConnectionStart":188.80000001192093},{"duration":537.0999999940395,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":402,"connectEnd":402,"connectStart":402,"domainLookupEnd":402,"domainLookupStart":402,"fetchStart":402,"redirectEnd":0,"redirectStart":0,"requestStart":402,"responseEnd":939.0999999940395,"responseStart":939.0999999940395,"secureConnectionStart":402},{"duration":250.40000000596046,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":695.0999999940395,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":695.0999999940395,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":945.5,"responseStart":0,"secureConnectionStart":0},{"duration":13.400000005960464,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/e65b778d185daf5aee24936755b43da6/_/download/contextbatch/js/browser-metrics-plugin.contrib,-_super,-project.issue.navigator,-jira.view.issue,-atl.general/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":943.9000000059605,"connectEnd":943.9000000059605,"connectStart":943.9000000059605,"domainLookupEnd":943.9000000059605,"domainLookupStart":943.9000000059605,"fetchStart":943.9000000059605,"redirectEnd":0,"redirectStart":0,"requestStart":943.9000000059605,"responseEnd":957.3000000119209,"responseStart":957.3000000119209,"secureConnectionStart":943.9000000059605}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":10,"responseStart":180,"responseEnd":182,"domLoading":183,"domInteractive":1015,"domContentLoadedEventStart":1015,"domContentLoadedEventEnd":1055,"domComplete":1249,"loadEventStart":1249,"loadEventEnd":1250,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":996.9000000059605},{"name":"bigPipe.sidebar-id.end","time":997.7000000178814},{"name":"bigPipe.activity-panel-pipe-id.start","time":997.9000000059605},{"name":"bigPipe.activity-panel-pipe-id.end","time":999},{"name":"activityTabFullyLoaded","time":1070.300000011921}],"measures":[],"correlationId":"cce52352758e71","effectiveType":"4g","downlink":9.9,"rtt":0,"serverDuration":108,"dbReadsTimeInMs":13,"dbConnsTimeInMs":21,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
It looks that the error returned from optimistic async replication applying conflicts is treated as galera cluster failure. The failure should instead be returned to optimistic replication control, where retrying should be handled. I will prepare a pull request for refactoring this failure handling.