jenkins-bot has submitted this change and it was merged.

Change subject: API: Remove index forcing in ApiQueryRecentChanges
......................................................................


API: Remove index forcing in ApiQueryRecentChanges

It's preventing better indexes from being chosen; hopefully removing it
doesn't cause worse indexes to be chosen anymore in other cases.

Bug: T140108
Change-Id: Iee480e221dc26f89e8583be5f26c6571b240e390
---
M includes/api/ApiQueryRecentChanges.php
1 file changed, 0 insertions(+), 3 deletions(-)

Approvals:
  Jcrespo: Looks good to me, but someone else must approve
  Legoktm: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/api/ApiQueryRecentChanges.php 
b/includes/api/ApiQueryRecentChanges.php
index f0fd2f4..63c95d3 100644
--- a/includes/api/ApiQueryRecentChanges.php
+++ b/includes/api/ApiQueryRecentChanges.php
@@ -150,7 +150,6 @@
                 *              AND rc_timestamp < $end AND rc_namespace = 
$namespace
                 */
                $this->addTables( 'recentchanges' );
-               $index = [ 'recentchanges' => 'rc_timestamp' ]; // May change
                $this->addTimestampWhereRange( 'rc_timestamp', $params['dir'], 
$params['start'], $params['end'] );
 
                if ( !is_null( $params['continue'] ) ) {
@@ -246,7 +245,6 @@
 
                if ( !is_null( $params['user'] ) ) {
                        $this->addWhereFld( 'rc_user_text', $params['user'] );
-                       $index['recentchanges'] = 'rc_user_text';
                }
 
                if ( !is_null( $params['excludeuser'] ) ) {
@@ -362,7 +360,6 @@
 
                $this->token = $params['token'];
                $this->addOption( 'LIMIT', $params['limit'] + 1 );
-               $this->addOption( 'USE INDEX', $index );
 
                $count = 0;
                /* Perform the actual query. */

-- 
To view, visit https://gerrit.wikimedia.org/r/298495
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iee480e221dc26f89e8583be5f26c6571b240e390
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Anomie <[email protected]>
Gerrit-Reviewer: Jcrespo <[email protected]>
Gerrit-Reviewer: Legoktm <[email protected]>
Gerrit-Reviewer: Reedy <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to