Page MenuHomePhabricator

Extension Duplicator needs to be updated due to MCR schema changes
Open, Needs TriagePublic

Description

Reported at https://www.mediawiki.org/wiki/Topic:Uvk534c3g65obfzp.

From @daniel :

Looking at https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/extensions/Duplicator/+/master/Duplicator.page.php it seems like Duplicator is incompatible with the MCR database schema (and will break for Actor migration and Comment migration as well).

To be MCR compatible, it will (depending on the $wgMultiContentRevisionSchemaMigrationStage) also copy the relevant rows in the slots table (entries in the content table can be shared between page copies), and possibly ignore the rev_text_id field. Similarly, depending on the value of $wgCommentTableSchemaMigrationStage and $wgActorTableSchemaMigrationStage, it needs to handle rev_user_text and rev_comment differently.

To remove the need for the extension to bind to the concrete database schema (not to migration stage config), it should probably create a new MutableRevisionRecord for each RevisionStoreRecord of the existing page, and use a PageUpdater to save them to the new page. This would completely hide any DB schema details, but it would also be slower. Some tweaks in core may be needed to enable sharing of content between pages, core currently only supports this between revisions on the same page at the moment.

Related Objects

StatusSubtypeAssignedTask
Declineddchen
OpenNone
OpenNone
DuplicateNone
OpenNone
OpenNone
OpenNone
StalledNone
OpenNone
DuplicateNone
ResolvedNone
OpenNone
OpenNone
OpenNone
OpenNone
ResolvedNone
ResolvedNone
OpenNone
StalledNone
OpenNone
OpenNone
OpenNone
OpenKizule

Event Timeline

Change 644546 had a related patch set uploaded (by Zoranzoki21; owner: Zoranzoki21):
[mediawiki/extensions/Duplicator@master] Make extension compatible with the current content of revision table

https://gerrit.wikimedia.org/r/644546

Change 644546 abandoned by Zoranzoki21:
[mediawiki/extensions/Duplicator@master] Make extension compatible with the MediaWiki 1.35 and newer

Reason:
Let's work on one by one option.

https://gerrit.wikimedia.org/r/644546