Skip to content

test: speed projected volume updates in Kind qualification - #2124

Merged
jbeda merged 1 commit into
mainfrom
test/k8s-fast-projection-fixture
Oct 6, 2026
Merged

jbeda merged 1 commit into
mainfrom
test/k8s-fast-projection-fixture

Conversation

@jbeda

@jbeda jbeda commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Configure a five-second kubelet sync period only in the disposable production Kind qualification cluster; keep the default Kubernetes behavior in deployment manifests and the development profile.
  • Preserve the same security rotation tests, timeouts, and assertions. The provider still loads projected Secrets and manifests and advances the durable authority ledger; this only changes how often the Kind kubelet reconciles projected volumes.
  • Add an offline test that executes the Kind-config branch, parses the rendered config, and checks the production-only kubelet patch.

Why

The baseline production Kind job took 67s/68s/60s for the three post-apply security ledger waits, with <1s API applies. Kubernetes documents a default kubelet syncFrequency of 1m and that projected Secret updates can take a sync period plus cache propagation; Kind supports patching KubeletConfiguration in its cluster config. This is a fixture-specific speed trial, not a change to production behavior.

Local comparison

  • Verified the effective Kind node config reads syncFrequency: 5s without reading security material.
  • Full local production qualification passed, with CI-owned cluster removed. Rotation fell from 380s to 132s; bridge/final/restore ledger waits from 51s/47s/71s to 7s/4s/4s. Helm lifetime fell from ~181s to 99s. Total test phase fell from 1252s to 871s (~6m21s). These are separate local runs; see CI result below.
  • Build/image caches differed (158s versus 64s), so do not use local job-wall difference as the speed claim.

Verification

  • go test ./deploy/mecatl-execution-kind -count=1
  • task test
  • Local MECATL_EXECUTION_QUAL_CI=1 task e2e:k8s:execution:production passed; no cluster retained.
  • task lint, task test:race, and offline demo passed. The first race run timed out in unrelated TestMicroVMChildRetainsParentSourceAfterRetirement after 10m; that test passed in isolation, and the full race gate passed on retry.

CI comparison

The production Kind job and ordinary Kind job passed. Against the baseline job:

Stage Baseline 5s fixture
Rotation test 405s 129s
Helm lifetime 181s 104s
All tests 1344s 935s (−6m49s)
Deployment setup 110s 333s (+3m43s)
Cluster + network + images + deployment + tests ~1801s ~1600s (−3m21s)

The setup outlier was a ~295s gap between provider scale-down and legacy executor Pod readiness (versus ~73s in baseline), a phase that also runs the legacyfixture go run before waiting for Pods (run.sh:353-359). The log cannot assign that gap to compilation versus scheduling; don't attribute the setup regression to the kubelet patch without evidence. The test-phase gain is independently reproduced locally and in CI. Even if retained, this does not alone solve the ~30-minute pipeline; larger reductions require a separate coverage-preserving design, not shorter safety waits.

@jbeda
jbeda marked this pull request as ready for review October 5, 2026 23:56
@jbeda
jbeda merged commit 4b7abcd into main Oct 6, 2026
63 checks passed
@jbeda
jbeda deleted the test/k8s-fast-projection-fixture branch October 6, 2026 15:39
@toolhive-release-app toolhive-release-app Bot mentioned this pull request Oct 7, 2026
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant