Brion Vibber wrote:
In rendering land, the winner is
OutputPage::replaceInternalLinks(). The
more links in the page, the longer (and longer) this takes. Through the
link cache, it makes a database query for every individual linked page
to check if it exists. More detail should be checked for this to see how
much of that time is spent in db queries; but I suspect that pre-filling
the link cache from the links and brokenlinks tables should speed this
up.
Just turn on the stub detector and watch it take even longer ;-)
Seriously: On Phase II (RIP), I put all the existing (and broken) links
into some text field. Maybe we should do that again for existing links
*in addition* to the existing link table. We would get that list in the
same query as the article body (no additional SQL query at all!)
Then, we check if all the other links are broken, maybe write the "short
list" back, and be done. Imagine: Not a single additional query for the
Main Page!
The only thing we'd have to do is clear some of these "short lists" on
page deletion. Shouldn't be a problem.
Magnus