Skip to content

fix(ci): trigger in-flight renewal and reuse qualified live deployment - #2280

Merged
JAORMX merged 4 commits into
mainfrom
fix/2257-controlled-renewal-live-handoff
Oct 13, 2026
Merged

JAORMX merged 4 commits into
mainfrom
fix/2257-controlled-renewal-live-handoff

Conversation

@JAORMX

@JAORMX JAORMX commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Follow-up to #2257 and merged #2276; implements the two next optimizations approved by the operator.

  1. Replace the in-flight test's scheduled-renewal wait with pinned, checksum-verified cmctl renew, invoked only after the command is demonstrably active. Observe actual certificate issuance, provider projected-volume reload, and a renewed handshake on the same client before releasing a bounded command barrier. Preserve terminal receipt, output, workspace/PVC/Pod/authority identity and subsequent mutation checks. Natural-expiry qualification remains opt-in and unchanged.
  2. In native CI, run the full deterministic mock proof once, last, after all other serial and renewal phases. Publish a same-run qualified-state digest only on success. Validate it in a secret-free step before private credential staging, then revalidate before Kubernetes Secret staging. Reuse the exact qualified images/deployment rather than rebuilding/reinstalling and rerunning the same proof. Standalone live preparation retains its existing path.

The handoff binds reviewed SHA, GitHub run/attempt, owned cluster/state/context, installed provider/agent/OIDC specs, image descriptors, template catalog, public authority/trust, and policy/service/RBAC wiring. Missing or drifted requested reuse fails closed; no fallback or historical qualification receipt. No production TLS/authorization/fencing semantics are changed.

Measured CI results

Measurement #2276 baseline This follow-up
Ordinary production qualification 39m01s 25m42s
Ordinary mandatory in-flight renewal 8m56.40s 25.77s
Native production prerequisite 38m46s 30m17s
Native mandatory in-flight renewal 10m08.59s 28s
Native coding step including preparation 7m21s 2m45s
Native total job excluding queue 47m35s 34m31s

The native job is 13m04s shorter (27.5%). These are measured run-to-run comparisons; runner/cache load, issuer timing, and model latency vary. Ordinary/native production totals are not an isolated comparison of their mock-proof order.

Evidence

  • Final-head ordinary Kind run 38380821343 passed at 4d34d83338efb327cfa049dd4f7146b4c80f4c6f. Production step ran 10:05:18–10:31:00 UTC. Logs show transport_reloaded_during_rpc=true, TestKindExecutionInFlightAutomaticRenewal (25.77s) passing, and the controlled-renewal phase completing in 26s.
  • Final-head full CI 38380821362 passed, including Test (race). Performance, Deslop, documentation, and both Kind jobs passed; no pending or failing checks at validation.
  • Native run 38376266836 passed at implementation commit 807771c54199d9076c056904aabca715f17fc509. The only later commit aligns architecture documentation; implementation/workflow are unchanged. Native final mock ran exactly once after the other phases (217s); secret-free verification and live preparation reuse passed. Typed live checks, restart verification, persisted-marker continuation, mock restoration, run-scoped credential cleanup and owned-cluster cleanup all passed.

Coverage and caveats

Behavioral tests cover renewal ordering, early completion/failure, exact cmctl/executable arguments, checksum rejection, same-client transport replacement, server-observed renewed client certificate identity, installed-resource drift, credential gates, and standalone preparation. Existing lower-layer expiry, trust-withdrawal, coherent reload, and fencing coverage is retained.

The initial ordinary Kind run at 807771c failed in unchanged serial tests: ScopedAdministrator's first ensure returned an internal error and ClearForkLifecycle returned HTTP 409, before reaching renewal. Both passed in the same-SHA native run and the final-head ordinary run. Bounded diagnostics omit the decisive provider error and 409 problem code, so the exact causes are not established; no flaky classification or check weakening is claimed. Triage and native evidence.

Per operator request, no local tests/builds/lint/docs gates were run. Validation was entirely CI-based. Static multi-axis review has no outstanding blocking or important findings; a source-order tripwire remains supplemental to behavioral tests. Explicit natural-expiry runtime qualification was not rerun; its test body remains unchanged.

JAORMX and others added 4 commits October 13, 2026 12:06
Bind the issuer deployment and readiness into the same-run handoff, select current issued identities for the final mock, and prove same-client transport renewal with an authenticated catalog RPC. Add behavioral drift and renewal controls without production instrumentation.

Co-authored-by: Mecatl <[email protected]>
@JAORMX
JAORMX marked this pull request as ready for review October 13, 2026 10:04
@JAORMX

JAORMX commented Oct 13, 2026

Copy link
Copy Markdown
Contributor Author

Native CI: both optimizations validated

Native run 38376266836 passed at implementation commit 807771c54199d9076c056904aabca715f17fc509. Subsequent commit 4d34d83338efb327cfa049dd4f7146b4c80f4c6f only aligns architecture documentation; implementation and workflow are unchanged.

Measurement #2276 baseline This follow-up
Native production prerequisite 38m46s 30m17s
Mandatory in-flight renewal 10m08.59s 28s
Native coding step (including prerequisite overhead) 7m21s 2m45s
Total native job, excluding queue 47m35s 34m31s

Measured total reduction: 13m04s (27.5%). These are run-to-run observations, not isolated benchmarks.

The controlled renewal ran while the original command was active and passed. Native production deferred the exact full mock test to its final phase and ran it once (217s). Secret-free handoff verification passed before private credential staging; live revalidation logged preparation reuse. Typed live verification, restart verification, persisted-marker continuation, mock restoration, run-scoped credential cleanup, and owned-cluster cleanup all passed.

Ordinary CI and caveat

The first ordinary Kind run failed in unchanged serial tests (ScopedAdministrator ensure returned internal error; ClearForkLifecycle returned HTTP 409), before reaching renewal. Both tests passed in the same-SHA native run. Bounded diagnostics omit the decisive provider error and 409 problem code, so the exact causes remain unestablished—not labelled confirmed flakes, and no checks were weakened. The final documentation push has initiated fresh PR checks; readiness also enables full race testing. New ordinary production results will follow.

No local tests/builds/lint were run. All validation is CI-based.

@JAORMX
JAORMX merged commit fd9a609 into main Oct 13, 2026
37 checks passed
@JAORMX
JAORMX deleted the fix/2257-controlled-renewal-live-handoff branch October 13, 2026 10:44
@toolhive-release-app toolhive-release-app Bot mentioned this pull request Oct 13, 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