← 输入框|github.com|刷新
Skip to content

[pipeline-manager] keep the bootstrap config through a stop request in the model. - #7779

Merged
ryzhyk merged 1 commit into
mainfrom
issue-7666
Nov 3, 2026
Merged

ryzhyk merged 1 commit into
mainfrom
issue-7666

Conversation

@ryzhyk

@ryzhyk ryzhyk commented Nov 2, 2026

Copy link
Copy Markdown
Contributor

A stop request clears bootstrap_policy together with deployment_initial only while the pipeline is still Stopped; otherwise both stay until the pipeline becomes Stopping. The implementation does this, and the pipeline lifecycle docs specify it. The model's two desired-Stopped setters cleared bootstrap_policy unconditionally, so db_impl_behaves_like_model failed whenever its generator stopped a Provisioning pipeline and read it back.

stop_request_keeps_bootstrap_config_of_started_deployment pins both setters deterministically; the property test never calls the forced one.

Linked Issue

Fixes #7666

Describe Manual Test Plan

Checklist

  • Unit tests added/updated
  • Integration tests added/updated
  • Documentation updated
  • Changelog updated

Breaking Changes?

Mark if you think the answer is yes for any of these components:

Describe Incompatible Changes

…n the model

A stop request clears `bootstrap_policy` together with `deployment_initial` only
while the pipeline is still `Stopped`; otherwise both stay until the pipeline
becomes `Stopping`. The implementation does this, and the pipeline lifecycle
docs specify it. The model's two desired-`Stopped` setters cleared
`bootstrap_policy` unconditionally, so `db_impl_behaves_like_model` failed
whenever its generator stopped a `Provisioning` pipeline and read it back.

`stop_request_keeps_bootstrap_config_of_started_deployment` pins both setters
deterministically; the property test never calls the forced one.

Fixes #7666

Signed-off-by: Leonid Ryzhyk <ryzhyk@gmail.com>
@ryzhyk
ryzhyk requested a review from gz November 2, 2026 00:48
@ryzhyk ryzhyk added Pipeline manager Pipeline manager (API, API server, runner, compiler server) QA Testing and quality assurance labels Nov 2, 2026
@mythical-fred-oss

Copy link
Copy Markdown
Contributor

LGTM. The model fix matches set_deployment_resources_desired_status in operations/pipeline.rs: on a stop request, (deployment_initial, bootstrap_policy) are cleared together only when the pipeline is Stopped.

Check Result
cargo test -p pipeline-manager --lib stop_request_keeps_bootstrap_config ✅ pass
Same test with the forced setter's old bootstrap_policy = None put back ❌ fails at Provisioning (forced: true), so the new test catches the regression
db_impl_behaves_like_model ×3 (RUST_MIN_STACK=16M) ✅ pass (~150s each)
pre-commit run --files test.rs ✅ pass

Observation: with the default stack, db_impl_behaves_like_model overflows in a local debug build. This is not caused by this PR and doesn't block it.

@ryzhyk
ryzhyk added this pull request to the merge queue Nov 3, 2026
Merged via the queue into main with commit 93e30c7 Nov 3, 2026
3 checks passed
@ryzhyk
ryzhyk deleted the issue-7666 branch November 3, 2026 06:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Pipeline manager Pipeline manager (API, API server, runner, compiler server) QA Testing and quality assurance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

db_impl_behaves_like_model: proptest finds stale bootstrap_policy divergence between model and real DB impl

2 participants