Make Title::getFirstRevision() ignore the rev_timestamp index
authorRoan Kattouw <roan.kattouw@gmail.com>
Tue, 28 Mar 2017 15:34:56 +0000 (11:34 -0400)
committerRoan Kattouw <roan.kattouw@gmail.com>
Wed, 29 Mar 2017 15:40:12 +0000 (11:40 -0400)
commitdee457713b1b110bff1dc9985eabd487c5d8877c
treef71b7edec0d51b1e162d6babcca890bb38a61146
parent17eba67ef329fb8f444f681e6ff515d1919376cb
Make Title::getFirstRevision() ignore the rev_timestamp index

We want the page_timestamp index to be used in this case, but sometimes
the rev_timestamp is chosen which leads to bad performance.

Also update WikiPage::getOldestRevision() which uses the exact same query.
I'll implement one in terms of the other in a follow-up commit.

Bug: T159319
Change-Id: I7c5c0a9b1af99ce2b5f4bdcc99710d8400ca8bcf
includes/Title.php
includes/page/WikiPage.php