Page MenuHomePhabricator

Call CompareService::getTotalEditsFromIp for each IP instead of each row
Closed, ResolvedPublic2 Estimated Story Points


As discussed in T248588#6131426, this query need only be run once for each IP in compare check results. Instead it is currently being run once for each result row. Since rows can contain the same IP, that means it is being repeated unnecessarily.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMay 13 2020, 10:04 AM
Niharika triaged this task as Medium priority.May 13 2020, 3:57 PM
Niharika moved this task from Untriaged to Cards ready to be discussed on the Anti-Harassment board.
ARamirez_WMF set the point value for this task to 1.May 13 2020, 4:09 PM
ARamirez_WMF changed the point value for this task from 1 to 2.May 13 2020, 4:19 PM
dmaza claimed this task.Jun 11 2020, 4:07 AM

Change 605395 had a related patch set uploaded (by Dmaza; owner: Dmaza):
[mediawiki/extensions/CheckUser@master] Cache CompareService::getTotalEditsFromIp result in an array

Change 605395 merged by jenkins-bot:
[mediawiki/extensions/CheckUser@master] Cache CompareService::getTotalEditsFromIp result in an array

dom_walden added a subscriber: dom_walden.

I looked at the logs for a couple of different investigations.

Checked that for each IP in the Compare table there was one (and only one) call to getTotalEditsFromIp for that IP.

This true also when IPs have been filtered out (we don't make a call to getTotalEditsFromIp for filtered out IPs).

Test environment: vagrant MediaWiki 1.35.0-alpha (6c57976).

Niharika closed this task as Resolved.Jul 27 2020, 6:06 PM