Support for targeting "next" deployments of in-scope MediaWiki instances based on enrollment cookie via ATS plugin.
[…]
The mechanism is controlled via the $wgWMENewPHPVersion and $wgWMENewPHPSamplingRate MediaWiki configuration variables, which default to "" and 0 respectively.
When set, the above JavaScript code (already enabled in production today) will create a 7-day PHP_ENGINE cookies, set to the value of $wgWMENewPHPVersion.
When the traffic is at 0%, or if you want to force your own opt-in for any reason when your own random cookie happens to be outside the bucket, you can use the PHP_ENGINE_STICKY=1 cookie to force the client logic to preserve any manaully set PHP_ENGINE=8.1 cookie, as follows:
Browser console$.cookie( 'PHP_ENGINE', version, { expires: 30, path: '/' } ); $.cookie( 'PHP_ENGINE_STICKY', '1', { expires: 30, path: '/' } );Cookies like PHP_ENGINE=8.1 are expected to be handled at either the edge or appserver layer. Previously this was handled in Varnish and Apache. Now, on mw-on-k8s, I imagine this will be in hanled in an ATS plugin.