MediaWiki
REL1_22
|
Maintenance script that sends purge requests for pages edited in a date range to squid/varnish. More...
Public Member Functions | |
__construct () | |
execute () | |
Protected Member Functions | |
pageableSortedRows (ResultWrapper $res, $column, $limit) | |
Remove all the rows in a result set with the highest value for column $column unless the number of rows is less $limit. |
Maintenance script that sends purge requests for pages edited in a date range to squid/varnish.
Can be used to recover from an HTCP message partition or other major cache layer interruption.
Definition at line 36 of file purgeChangedPages.php.
Reimplemented from Maintenance.
Definition at line 38 of file purgeChangedPages.php.
References Maintenance\addOption(), and Maintenance\setBatchSize().
Reimplemented from Maintenance.
Definition at line 50 of file purgeChangedPages.php.
References $dbr, $res, $title, $urls, array(), as, Maintenance\error(), Maintenance\getDB(), Maintenance\getOption(), global, Maintenance\hasOption(), list, Title\makeTitle(), Maintenance\maybeHelp(), Maintenance\output(), and pageableSortedRows().
PurgeChangedPages::pageableSortedRows | ( | ResultWrapper $ | res, |
$ | column, | ||
$ | limit | ||
) | [protected] |
Remove all the rows in a result set with the highest value for column $column unless the number of rows is less $limit.
This returns the new array of rows and the highest value of column $column for the rows left. The ordering of rows is maintained.
This is useful for paging on mostly-unique values that may sometimes have large clumps of identical values. It should be safe to do the next query on items with a value higher than the highest of the rows returned here. If this returns an empty array for a non-empty query result, then all the rows had the same column value and the query should be repeated with a higher LIMIT.
: move this elsewhere
ResultWrapper | $res | Query result sorted by $column (ascending) |
string | $column |
Definition at line 169 of file purgeChangedPages.php.
References $count, $limit, and array().
Referenced by execute().