Page MenuHomePhabricator

Allow tracking of max run time / conditions consumed in AbuseFilter
Open, LowPublic

Description

Right now AbuseFilter provides per filter stats on mean run time and number of conditions utilized (or it would if it wasn't horribly broken per T53294). I would like to propose adding stats on max run time / conditions to help identify filters that are sometimes very slow but only rarely so. Since most filters have a series of fast early selections criteria (e.g. checking article namespace or not autoconfirmed user) it isn't always obvious how fast or slow the guts of the filter may be. Recording the longest run time in an observed sample would help to identify filters that occasionally perform badly. The present system tracks the mean properties of the last 10,000 actions, and also adding the max values to the statistics would not be difficult.

Event Timeline

Dragons_flight raised the priority of this task from to Normal.
Dragons_flight updated the task description. (Show Details)
Dragons_flight added a project: AbuseFilter.
Dragons_flight added a subscriber: Dragons_flight.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptFeb 25 2015, 6:38 PM
Aklapper lowered the priority of this task from Normal to Low.Mar 3 2015, 2:05 PM

Change 201171 that I wrote includes this functionality as part of its changes:

Expands stat tracking in AbuseFilter
https://gerrit.wikimedia.org/r/201171

He7d3r added a subscriber: He7d3r.Jun 7 2015, 3:39 PM
Zache added a subscriber: Zache.Sep 27 2016, 2:19 PM

Change 201171 had a related patch set uploaded (by Daimona Eaytoy; owner: Dragons flight):
[mediawiki/extensions/AbuseFilter@master] Expand stat tracking in AbuseFilter

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

An important note which I'm putting here as a reminder: if we merge the patch for T53294 and let it live and register even a single edit, when these stats will be added some errors will start to pop up due to missing data in old entries. A solution could be to delete all stash keys, set AbuseFilterProfileActionsCap to 0 (no profiling), deploy this and then re-enable profiling.

Daimona claimed this task.Oct 21 2018, 12:17 PM

Claiming as I took over the patch.