On Fri, Jan 21, 2011 at 10:43 AM, Roan Kattouw <roan.kattouw(a)gmail.com>wrote;wrote:
2011/1/21 Platonides <Platonides(a)gmail.com>om>:
If we wanted to map it to a page/revision format,
it seems quite
straightforward. I'm missing something, right?
You're missing that migrating a live site (esp. Commons, with 8
million image rows and ~750k oldimage rows) from the old to the new
schema would be a nightmare, and would probably involve setting stuff
to read-only for a few hours.
If one's clever about it, this could probably actually be done on-the-fly in
a reasonably non-evil fashion.
Image version data isn't used as widely as revisions; eg things like
Special:Contributions always needed direct access to old revs looked up by
author, whereas I think image old versions are pretty much only pulled up by
title, via the image record. There are also relatively few revisions per
file -- old images usually only have a few revisions, and cases of thousands
of versions are I suspect very rare -- which would make the actual
conversion work relatively lightweight for each file record.
Further optimizing by delaying on-demand migration of a record until write
time could also keep it from being a sudden database & i/o sink. If indirect
lookups won't be needed, we can just keep reading the existing
image/oldimage records until they need to be updated on modification (or get
updated by a background task at leisure).
-- brion