Remove unnecessary exception from Title::getLatestRevID()
authorTim Starling <tstarling@wikimedia.org>
Thu, 6 Jun 2013 06:45:50 +0000 (16:45 +1000)
committerSiebrand Mazeland <s.mazeland@xs4all.nl>
Tue, 11 Jun 2013 06:58:32 +0000 (08:58 +0200)
commit22e2e96088d81022cb40e9991683a335029e7565
treeab2339d6597e8165837e3ae3c1dff1c0a92cec87
parent5b0939fa1956f5bc2c936510c64395d9c74ac739
Remove unnecessary exception from Title::getLatestRevID()

Bug 37209: An exception was thrown where the data cached in the Title
object was inconsistent with the data in LinkCache. It shouldn't be
surprising that this happens, since there is no guarantee that the data
was derived from the same transaction or even the same DB server.

But I don't think it is a problem worth troubling the user over, since
with $flags=0, the slave DB server will be used, and no special guarantee
of consistency should be expected by callers. If callers do need
consistency, then they should make their own arrangements to get it,
such as clearing the LinkCache.

Since we have to pick a winner, and the choice is mostly arbitrary since
it's not possible to tell which is fresher, I think LinkCache is a better
choice since the lifetime of its cache entries can be controlled.

Change-Id: I0add48463341e56fe8c155b1007487278ad2705d
includes/Title.php