Engine-independent online alter table (MDEV-16329) brings an extra data-modification stage to the COPY alter table – online log changes application.
For the normal copy stage, the row-by-row logging was disabled in MDEV-11415. This can be extended to the online log application.
{"report":{"fcp":1041.4000000953674,"ttfb":251.70000004768372,"pageVisibility":"visible","entityId":127031,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":0.5,"journeyId":"31e37274-7c3b-46a1-ba29-3ac9333d575c","navigationType":0,"readyForUser":1115,"redirectCount":0,"resourceLoadedEnd":1152.2999999523163,"resourceLoadedStart":257.2000000476837,"resourceTiming":[{"duration":261.39999985694885,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":257.2000000476837,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":257.2000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":518.5999999046326,"responseStart":0,"secureConnectionStart":0},{"duration":261.40000009536743,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/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&whisper-enabled=true","startTime":257.5,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":257.5,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":518.9000000953674,"responseStart":0,"secureConnectionStart":0},{"duration":269.7000000476837,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":257.7999999523163,"connectEnd":257.7999999523163,"connectStart":257.7999999523163,"domainLookupEnd":257.7999999523163,"domainLookupStart":257.7999999523163,"fetchStart":257.7999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":257.7999999523163,"responseEnd":527.5,"responseStart":527.5,"secureConnectionStart":257.7999999523163},{"duration":383.2000000476837,"initiatorType":"script","name":"https://jira.mariadb.org/s/2d8175ec2fa4c816e8023260bd8c1786-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/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&whisper-enabled=true","startTime":258,"connectEnd":258,"connectStart":258,"domainLookupEnd":258,"domainLookupStart":258,"fetchStart":258,"redirectEnd":0,"redirectStart":0,"requestStart":258,"responseEnd":641.2000000476837,"responseStart":641.0999999046326,"secureConnectionStart":258},{"duration":386.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/a9324d6758d385eb45c462685ad88f1d-CDN/lu2cib/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":258.2000000476837,"connectEnd":258.2000000476837,"connectStart":258.2000000476837,"domainLookupEnd":258.2000000476837,"domainLookupStart":258.2000000476837,"fetchStart":258.2000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":258.2000000476837,"responseEnd":644.7000000476837,"responseStart":644.7000000476837,"secureConnectionStart":258.2000000476837},{"duration":386.90000009536743,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":258.2999999523163,"connectEnd":258.2999999523163,"connectStart":258.2999999523163,"domainLookupEnd":258.2999999523163,"domainLookupStart":258.2999999523163,"fetchStart":258.2999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":258.2999999523163,"responseEnd":645.2000000476837,"responseStart":645.2000000476837,"secureConnectionStart":258.2999999523163},{"duration":387.09999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":258.5,"connectEnd":258.5,"connectStart":258.5,"domainLookupEnd":258.5,"domainLookupStart":258.5,"fetchStart":258.5,"redirectEnd":0,"redirectStart":0,"requestStart":258.5,"responseEnd":645.5999999046326,"responseStart":645.5999999046326,"secureConnectionStart":258.5},{"duration":413.39999985694885,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2cib/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":258.7000000476837,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":258.7000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":672.0999999046326,"responseStart":0,"secureConnectionStart":0},{"duration":387.09999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":258.90000009536743,"connectEnd":258.90000009536743,"connectStart":258.90000009536743,"domainLookupEnd":258.90000009536743,"domainLookupStart":258.90000009536743,"fetchStart":258.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":258.90000009536743,"responseEnd":646,"responseStart":646,"secureConnectionStart":258.90000009536743},{"duration":413.2000000476837,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2cib/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":259.09999990463257,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":259.09999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":672.2999999523163,"responseStart":0,"secureConnectionStart":0},{"duration":387.40000009536743,"initiatorType":"script","name":"https://jira.mariadb.org/s/5d5e8fe91fbc506585e83ea3b62ccc4b-CDN/lu2cib/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":259.2999999523163,"connectEnd":259.2999999523163,"connectStart":259.2999999523163,"domainLookupEnd":259.2999999523163,"domainLookupStart":259.2999999523163,"fetchStart":259.2999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":259.2999999523163,"responseEnd":646.7000000476837,"responseStart":646.7000000476837,"secureConnectionStart":259.2999999523163},{"duration":548,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":265.40000009536743,"connectEnd":265.40000009536743,"connectStart":265.40000009536743,"domainLookupEnd":265.40000009536743,"domainLookupStart":265.40000009536743,"fetchStart":265.40000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":265.40000009536743,"responseEnd":813.4000000953674,"responseStart":813.4000000953674,"secureConnectionStart":265.40000009536743},{"duration":837.4000000953674,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":265.59999990463257,"connectEnd":265.59999990463257,"connectStart":265.59999990463257,"domainLookupEnd":265.59999990463257,"domainLookupStart":265.59999990463257,"fetchStart":265.59999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":265.59999990463257,"responseEnd":1103,"responseStart":1103,"secureConnectionStart":265.59999990463257},{"duration":130.79999995231628,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":683,"connectEnd":683,"connectStart":683,"domainLookupEnd":683,"domainLookupStart":683,"fetchStart":683,"redirectEnd":0,"redirectStart":0,"requestStart":683,"responseEnd":813.7999999523163,"responseStart":813.7999999523163,"secureConnectionStart":683},{"duration":208.29999995231628,"initiatorType":"link","name":"https://jira.mariadb.org/s/d5715adaadd168a9002b108b2b039b50-CDN/lu2cib/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/css/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":944,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":944,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1152.2999999523163,"responseStart":0,"secureConnectionStart":0}],"fetchStart":0,"domainLookupStart":55,"domainLookupEnd":60,"connectStart":60,"connectEnd":80,"secureConnectionStart":69,"requestStart":80,"responseStart":252,"responseEnd":265,"domLoading":256,"domInteractive":1178,"domContentLoadedEventStart":1178,"domContentLoadedEventEnd":1217,"domComplete":1476,"loadEventStart":1476,"loadEventEnd":1477,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1160.2000000476837},{"name":"bigPipe.sidebar-id.end","time":1160.9000000953674},{"name":"bigPipe.activity-panel-pipe-id.start","time":1161.0999999046326},{"name":"bigPipe.activity-panel-pipe-id.end","time":1162.7000000476837},{"name":"activityTabFullyLoaded","time":1236.7999999523163}],"measures":[],"correlationId":"9eb3750160b438","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":113,"dbReadsTimeInMs":15,"dbConnsTimeInMs":24,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
Row-by-row logging is enabled for CREATE...SELECT in select_create::prepare.
But it's turned off for IGNORE and REPLACE
table->file->extra(HA_EXTRA_BEGIN_ALTER_COPY);
git show c411393a844becf91a560ac8e53ab04cb4fb9219
commit c411393a844becf91a560ac8e53ab04cb4fb9219
Author: Marko Mäkelä <marko.makela@mariadb.com>
Date: Thu Jan 28 15:26:53 2021 +0200
MDEV-24715 Assertion !node->table->skip_alter_undo in CREATE...REPLACE SELECT
In commit 3cef4f8f0fc88ae5bfae4603d8d600ec84cc70a9 (MDEV-515)
we inadvertently broke CREATE TABLE...REPLACE SELECT statements
by wrongly disabling row-level undo logging.
select_create::prepare(): Only invoke extra(HA_EXTRA_BEGIN_ALTER_COPY)
if no special treatment of duplicates is needed.
REPLACE operation has a special treatment in comparison with UPDATE and DELETE – it needs row-grained logging to carefully rollback the failed row insertion inside the statement. In comparison, this would lead to a statement failure in INSERT/UPDATE/DELETE/CREATE...SELECT/ALTER TABLE.
Online ALTER does not allow the replace behavior for the online log application (neither it does for the copy stage as of now), so it should be safe