Page MenuHomePhabricator

EPIC: Test Kitchen: Implement non-cache-splitting experiments
Closed, ResolvedPublic

Description

Background

Not all everyone experiments require splitting the cache. So-called "non-first-paint features" – features where the UX is client-side-only – could be experimented on without splitting the cache. For example:

  • An experiment that varies the number of items in the search autocomplete
  • An experiment that varies whether descriptions are shown in the search autocomplete
  • An experiment that varies the delay before a Page Preview appears

Splitting the cache for these experiments wouldn't affect the experiment and would place an unnecessary burden on the edge caches and MediaWiki. We foresaw this some time ago and decided that, for this class of experiment, Varnish would continue to enrol users but send the enrolment information to the browser via a Server-Timing header instead of to MediaWiki.

This epic covers updating the JS xLab SDK to reconcile the information received from MediaWiki and from Varnish via the Server-Timing header.

Scenarios
1. Cache-Splitting Experiment

Consider the experiment "A" which has a "control" group and a "treatment" group and splits the cache. When the user is enrolled:

  • Varnish will split on a=treatment;
  • We should expect the following values:
Example Value
MediaWiki X-Experiment-Enrollments"a=treatment;"
EventGate X-Experiment-Enrollments"a=treatment/$aSubjectID;"
WMF-Uniq Server-Timing headera=treatment;
2. Non-Cache-Splitting Experiment

Consider the experiment "B" which has a "control" group and a "treatment" group and does not split the cache. When the user is enrolled:

  • Varnish will not split the cache
  • We should expect the following values:
Example Value
MediaWiki X-Experiment-Enrollments""
EventGate X-Experiment-Enrollments"b=control/$bSubjectID;"
WMF-Uniq Server-Timing headerb=control;
(1) & (2) Concurrently

Consider the A & B experiments running concurrently. When the user is enrolled:

  • Varnish will split the cache on a=treatment
  • We should expect the following values:
Example Value
MediaWiki X-Experiment-Enrollments"a=treatment"
EventGate X-Experiment-Enrollments"a=treatment/$aSubjectID;b=control/$bSubjectID;"
WMF-Uniq Server-Timing headera=treatment;b=control;

This epic covers the implementation of non-cache splitting experiments in Test Kitchen.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
JVanderhoop-WMF moved this task from Incoming to READY TO GROOM on the Test Kitchen board.
JVanderhoop-WMF subscribed.

This remains relevant with GrowthBook and with the Vision™

KReid-WMF renamed this task from EPIC: MetricsPlatform/xLab: Reconcile cache splitting and non-cache-splitting experiments to EPIC: Test Kitchen: Reconcile cache splitting and non-cache-splitting experiments.Feb 19 2026, 5:23 PM
phuedx renamed this task from EPIC: Test Kitchen: Reconcile cache splitting and non-cache-splitting experiments to EPIC: Test Kitchen: Implement non-cache-splitting experiments.Mar 10 2026, 10:17 AM
phuedx updated the task description. (Show Details)