That looks pretty fancy I must say !

On Wed, Aug 17, 2022 at 7:54 PM Ori Livneh <ori.livneh@gmail.com> wrote:
Hello,

A short while ago, the SRE Traffic team enabled query-string normalization for MediaWiki.org. This means that the caching layer (Varnish, specifically) now rewrites the query string portion of request URLs, so that query parameters are sorted by key. The re-written URL is then used for the cache look-up and (if necessary) the backend request. This improves the efficiency of the cache, since it allows logically-equivalent requests with different URL forms to be served by a single cache entry.

For example, this URL:
  https://www.mediawiki.org/w/index.php?title=Squid&action=history

Is re-written as:
  https://www.mediawiki.org/w/index.php?action=history&title=Squid

Care has been taken to make the sort stable for duplicate keys, and to handle PHP array syntax (?foo[]=a&foo[]=b) correctly.

MediaWiki.org is the first wiki that gets real traffic where this is enabled. If you encounter any weirdness, please file a task. If everything looks good, we'll proceed with an incremental roll-out to other wikis. This is tracked in T314868.

Cheers

_______________________________________________
Wikitech-l mailing list -- wikitech-l@lists.wikimedia.org
To unsubscribe send an email to wikitech-l-leave@lists.wikimedia.org
https://lists.wikimedia.org/postorius/lists/wikitech-l.lists.wikimedia.org/