pageid parser function is expensive, make it so
authorBrad Jorsch <bjorsch@wikimedia.org>
Tue, 14 Jan 2014 20:36:48 +0000 (15:36 -0500)
committerBrad Jorsch <bjorsch@wikimedia.org>
Tue, 14 Jan 2014 20:44:08 +0000 (15:44 -0500)
commit6131a214aa585d3cd0460551c2acd3927e930951
tree54ef517772bae2ccf7d34389cdf54c03ef326f6e
parent9f9031b53f25c197fd990900633d5103a155bafa
pageid parser function is expensive, make it so

The pageid parser function (not to be confused with the pageid magic
word) hits the database for every title passed, which meets the criteria
for being considered an expensive parser function.

To mitigate this new expensiveness, check for special namespaces,
interwiki titles, and titles in LinkCache before hitting the DB.

Also, record potentially-valid titles in pagelinks so that the page can
be properly purged if the target is created/deleted.

Change-Id: I4fbfc265543f0a64c14dc8a44e1c89cd928a1adb
includes/parser/CoreParserFunctions.php