Avoid master queries in Revision::newFromTitle(..., Revision::READ_NORMAL)
authorTim Starling <tstarling@wikimedia.org>
Fri, 7 Jun 2013 00:31:37 +0000 (10:31 +1000)
committerTim Starling <tstarling@wikimedia.org>
Wed, 23 Oct 2013 00:22:50 +0000 (00:22 +0000)
commite6b1baf240b8323ab092ce9be85050bf63336049
tree9f30846fce0f6a7e660719a15181787bb1b80556
parent02cad7573ed8655c87a3480dbee93005a2613a14
Avoid master queries in Revision::newFromTitle(..., Revision::READ_NORMAL)

The fallback to master makes sense in Revision::newFromId(), since a
revision ID known to exist by some other means might be present in the
master but not in the slave. But it doesn't make sense for
Revision::newFromTitle(), where by far the most common cause of this
case being hit is the page being nonexistent.

Change-Id: I41189fcde1b8065ac134982241376d63b78732a1
includes/Revision.php