MediaWiki REL1_31
CdnPurgeJob.php
Go to the documentation of this file.
1<?php
30class CdnPurgeJob extends Job {
35 function __construct( Title $title, array $params ) {
36 parent::__construct( 'cdnPurge', $title, $params );
37 $this->removeDuplicates = false; // delay semantics are critical
38 }
39
40 public function run() {
41 // Use purge() directly to avoid infinite recursion
42 CdnCacheUpdate::purge( $this->params['urls'] );
43
44 return true;
45 }
46}
static purge(array $urlArr)
Purges a list of CDN nodes defined in $wgSquidServers.
Job to purge a set of URLs from CDN.
__construct(Title $title, array $params)
run()
Run the job.
Class to both describe a background job and handle jobs.
Definition Job.php:31
array $params
Array of job parameters.
Definition Job.php:36
Represents a title within MediaWiki.
Definition Title.php:39