An idea from the RelEng team day at the Dec 2024 offsite: cache the build result of certain MW testsuite jobs based on the working directory state and any other relevant inputs.
We know that in many cases we run the same tests for the same pieces of code. What we don't know is whether the inputs for those tests are materially different from build to build or if we're running the same tests in the same way multiple times.
Details:
- It takes less than 10 minutes to branch MediaWiki
- We know this because we create a wmf/next branch nightly—wmf/next is equivalent to the new version we branch each week for the train, except it happens nightly
- It takes about 30 minutes for the branching job to complete
- This is due to the 20 minutes spent waiting for tests to complete
- If these tests are unnecessary, we'd like to avoid running those tests
- The first step in knowing if those tests are unnecessary is monitoring
Acceptance criteria:
- Build a plan for computing a cache key based on all relevant inputs for a given MW job (working directory state and perhaps some build parameters?)
- Stretch: implement cache key computation prior to test runs and track how many hits we get from build to build