Last modified: 2014-03-07 14:42:52 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T64356, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 62356 - SquidPurgeClient.php provides no hooks for extensions to purge individual files from non-Squid, non-Varnish content delivery networks
SquidPurgeClient.php provides no hooks for extensions to purge individual fil...
Status: NEW
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
1.23.0
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-03-07 02:10 UTC by Carl Austin Bennett
Modified: 2014-03-07 14:42 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Carl Austin Bennett 2014-03-07 02:10:30 UTC
SquidPurgeClient.php seems hard-coded so content delivery network (CDN) nodes are presumed to be Squid, compatible with HTTP PURGE sent from a trusted IP address.

This works if the cache acts like a Squid (Varnish is configurable to do this) but is problematic when dealing with commercial content delivery networks.

Services like CloudFlare (or Amazon AWS) expect the origin server to invoke their specific proprietary API to signal that a page or file has been superseded with updated content. 

HTTP PURGE likely doesn't even reach them as the long list of IPv4 / IPv6 ranges is normally handled with [[mw:extension:TrustedXFF]] or a proprietary module (like mod_cloudflare for Apache). Even if it were possible to list the entire CDN in $wgSquidServers, those servers would ignore a Squid-style PURGE message.

The end result is that plenty of outdated content is served as the CDN has no way to know a new version exists until the original version expires from cache.

There needs to be a way to replace the stock SquidPurgeClient with an extension which provides a function to purge CDN files, but I see no hooks in the code to allow this. There are [[mw:Manual:CloudFlare#HTTP_purge]] extensions for WordPress, Drupal and the like but nothing for MediaWiki as the hook to add such an extension does not exist.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links