Last modified: 2014-01-31 21:33:18 UTC
The table archive has a the old fields archive.ar_text/archive.ar_flags. Before removing that fields (bug 31223) a maintenance script is needed to move the text to the text table. Calling Revision::newFromArchiveRow for each row with archive.ar_text_id IS NULL to extract the text with all flags. But no idea how MediaWiki saves the text back to the right table and cleaning up the archive table, because we do not do undeletion (In that case Revision::insertOn does the work).
I am willing to work on this. I am new to mediawiki, so can someone please explain me what is to be done here?
Pawan: Comment 0 explains what needs to be done here. If something *specific* is unclear, please ask specific questions after you have found the code and taken a look at it to understand it.
Created attachment 14409 [details] Code for migration of the fields archive.ar_text and archive.ar_flags from archive table to text table
Comment on attachment 14409 [details] Code for migration of the fields archive.ar_text and archive.ar_flags from archive table to text table As I understand, the archive.ar_text and archive.ar_flags are to be migrated to text.old_text and text.old_flags I have added the first version of patch for the migration. Do comment on it. Further questions : 1. Should I delete the corresponding fields of the migrated entries from the archives table. Edit : I now realize that archive.ar_id should be migrated to text.old_id as well.I will do it in the next patch.
Hi Pawan! Thanks for your attachment! It's not a patch though but a code file. You are welcome to use Developer access https://www.mediawiki.org/wiki/Developer_access to submit a patch as a Git branch directly into Gerrit: https://www.mediawiki.org/wiki/Git/Tutorial Putting your branch in Git makes it easier to review it quickly. If you don't want to set up Git/Gerrit, you can also use https://tools.wmflabs.org/gerrit-patch-uploader/ Thanks again! We appreciate your contribution.
Change 110503 had a related patch set uploaded by Gerrit Patch Uploader: textMigration.php : Migration of text from archive table to text table https://gerrit.wikimedia.org/r/110503
Assigning this bug to myself, as I was already working on it (and at least at the moment, have more complete code).