Skip to content

feat(stovepipe): record partial validation and advance build baselines early - #922

Open
mnoah1 wants to merge 3 commits into
mainfrom
mnoah1/stovepipe-partial-baseline
Open

mnoah1 wants to merge 3 commits into
mainfrom
mnoah1/stovepipe-partial-baseline

Conversation

@mnoah1

@mnoah1 mnoah1 commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Why?

Successful builds should supply the next incremental baseline while project resolution is pending. Failed repositories with project results need a partial degree instead of the fully broken degree.

What?

  • Add DegreePartial = 0.5 for failed Requests with project results, preserving each project's resolved degree.
  • Resolve projects before recording facts; persist facts and history before promoting a green fact that still owns the baseline.
  • Preserve the existing slot release before saving the winning Request outcome. Advance a successful baseline in a separate Queue update before publishing to record; an admission between release and advancement may select the previous baseline. Terminal retries repeat the bookmark update without releasing the slot again.

Issue

None; this implements the agreed Stovepipe validation behavior.

Test Plan

Run ./tool/bazel test //stovepipe/... //service/stovepipe/server/... //test/integration/stovepipe/extension/storage/mysql:go_default_test //test/e2e/stovepipe:go_default_test --test_output=errors. All 28 targets pass, including replay, admission-baseline timing, project-resolution ordering, partial-degree, MySQL, and end-to-end coverage.

Formatting, lint, module-tidy, and Gazelle checks pass.

Revert Plan

Revert the application change. No database schema migration is required; existing immutable validation facts remain intact.

…s early

Summary:
## Why?
Successful builds should supply the next incremental baseline while project resolution is pending. Failed repositories with project results need a partial degree instead of the fully broken degree.

## What?
- Add DegreePartial = 0.5 for failed Requests with project results, preserving each project's resolved degree.
- Resolve projects before recording facts; persist facts and history before promoting a green fact that still owns the baseline.
- Share request-owned slot Claim and Complete operations. Save the winning Request outcome first, then atomically advance a successful baseline and release its Queue slot. Replays and DLQ recovery cannot release another Request's capacity.
- Append the MySQL slot-owner column and document the required drained rollout.

## Issue
None; this implements the agreed Stovepipe validation behavior.

Test Plan:
Run ./tool/bazel test //stovepipe/... //service/stovepipe/server/... //test/integration/stovepipe/extension/storage/mysql:go_default_test //test/e2e/stovepipe:go_default_test --test_output=errors. All 29 targets pass, including replay, admission-baseline timing, project-resolution ordering, partial-degree, MySQL, and end-to-end coverage.

Formatting, lint, module-tidy, and Gazelle checks pass. Before deployment, drain old work and stop all old Queue writers, append the nullable in_flight_request_ids JSON column, then deploy all Queue readers and writers together. See stovepipe/extension/storage/mysql/MIGRATIONS.md.

Revert Plan:
Drain and stop the new workers before reverting the application. Retain the nullable column; old binaries can ignore it once all owned reservations have completed. Do not run mixed old and new writers.
@mnoah1
mnoah1 marked this pull request as ready for review October 22, 2026 19:08
@mnoah1
mnoah1 requested review from a team, behinddwalls and sbalabanov as code owners October 22, 2026 19:08
@mnoah1
mnoah1 marked this pull request as draft October 22, 2026 19:24
@mnoah1
mnoah1 marked this pull request as ready for review October 22, 2026 19:31

This branch has not been deployed

No deployments
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