Last modified: 2014-03-04 02:15:42 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T63982, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 61982 - ApiQueryUserContributions Revision::getParentLengths wrong load balancing db connection
ApiQueryUserContributions Revision::getParentLengths wrong load balancing db ...
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
API (Other open bugs)
1.23.0
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
: performance
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-02-27 04:04 UTC by Sean Pringle
Modified: 2014-03-04 02:15 UTC (History)
5 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Sean Pringle 2014-02-27 04:04:40 UTC
This is very similiar to Bug 59987 and may need a similar fix.

ApiQueryContributions::execute calls Revision::getParentLengths thus:

$this->parentLens = Revision::getParentLengths( $this->getDB(), $revIds );

The DB handle returned by getDB() is initialized previously to use the 'contributions' name for the database load balancer. This is appropriate for ApiQueryContributions itself but less-so for Revision::getParentLengths as the latter query is quite different and limits the optimization options in the back end.

Consider passing a second normal slave connection instead.
Comment 1 Gerrit Notification Bot 2014-03-02 18:07:49 UTC
Change 116286 had a related patch set uploaded by Umherirrender:
Use a secondary db connection for Revsion::getParentLength in api

https://gerrit.wikimedia.org/r/116286
Comment 2 Gerrit Notification Bot 2014-03-04 02:15:03 UTC
Change 116286 merged by Springle:
Use a secondary db connection for Revsion::getParentLength in api

https://gerrit.wikimedia.org/r/116286

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links