Manuel:PurgeChangedFiles.php
Version de MediaWiki : | ≥ 1.22 |
Fichier MediaWiki : purgeChangedFiles.php | |
---|---|
Emplacement : | maintenance/ |
Code source : | master • 1.42.3 • 1.41.4 • 1.39.10 |
Classes : | PurgeChangedFiles |
Détails
Le fichier purgeChangedFiles.php est un script de maintenance qui balaie la table logging et purge les fichiers concernés et les vignettes dans un intervalle de temps. This script processes 100 items in a batch.
Options/Arguments
Option | Description | Required? |
---|---|---|
--starttime | Starting timestamp | obligatoire |
--endtime | Ending timestamp | obligatoire |
--type | Comma-separated list of types of changes to send purges for (created,deleted,modified,all) | optionnel |
--htcp-dest | HTCP announcement destination (IP:port) | optionnel |
--dry-run | Do not send purge requests | optionnel |
--sleep-per-batch | Milliseconds to sleep between batches | optionnel |
--verbose | Show more output | optionnel |
Usage
php maintenance/purgeChangedFiles.php --starttime dt1 --endtime dt2 [ --type| --htcp-dest| --dry-run| --sleep-per-batch| --verbose ]
Dry run to check purging
Terminal
$ php maintenance/purgeChangedFiles.php --starttime 20210101 --endtime 20211231 --dry-run Checking for created files... Scanning for upload/upload Scanning for import/upload,interwiki Checking for deleted files... Scanning for delete/delete,revision Scanning for suppress/delete,revision Checking for modified files... Scanning for upload/overwrite,revert Scanning for move/move,move_redir
Purging
Terminal
$ php maintenance/purgeChangedFiles.php --starttime 20210101 --endtime 20211231