Skip to content

docs: propose precise sandbox lifecycle states#653

Open
AiRanthem wants to merge 3 commits into
openkruise:masterfrom
AiRanthem:feature/extend-states-proposal-260716
Open

docs: propose precise sandbox lifecycle states#653
AiRanthem wants to merge 3 commits into
openkruise:masterfrom
AiRanthem:feature/extend-states-proposal-260716

Conversation

@AiRanthem

Copy link
Copy Markdown
Member

What changed

Adds the technical proposal for replacing the derived five-state Sandbox model with an eleven-state lifecycle through three ordered changes:

  1. define and exhaustively verify the pure lifecycle model and in-place failure stages;
  2. activate CR-based lookup and lifecycle routing on the approved short-ID Projector/Store/Repairer foundation;
  3. atomically migrate consumers and add public E2B projection, operation gates, and reasoned Sandbox 404s.

Why

The current dead state conflates completion, failure, controller progress, and temporary unavailability. This can produce false 404s, premature route deletion, and duplicated CRD-condition interpretation in sandbox-manager.

Review focus

  • lifecycle precedence and pre/update/post-mutation failure evidence;
  • strict ownership boundaries with the short-ID design;
  • route disposition and conditional peer deletion;
  • SandboxSet/accounting semantics and the atomic consumer cutover;
  • E2B public-state compatibility and the six 404 reasons.

Impact

Documentation only. No code, CRD schema, generated artifact, or public state enum changes are included in this PR.

Validation

  • Companion OpenSpec source on feature/extend-states-260715: 3/3 changes pass strict validation.
  • git diff --check passes.
  • Proposal branch contains exactly one new document.

Signed-off-by: AiRanthem <zhongtianyun.zty@alibaba-inc.com>
@kruise-bot

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign zmberg for approval by writing /assign @zmberg in a comment. For more information see:The Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@AiRanthem
AiRanthem marked this pull request as ready for review July 16, 2026 03:07
@codecov

codecov Bot commented Jul 16, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.05%. Comparing base (dee78fb) to head (e2d6ea9).
⚠️ Report is 6 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #653      +/-   ##
==========================================
- Coverage   80.06%   80.05%   -0.02%     
==========================================
  Files         229      229              
  Lines       17861    17862       +1     
==========================================
- Hits        14300    14299       -1     
- Misses       2976     2978       +2     
  Partials      585      585              
Flag Coverage Δ
unittests 80.05% <ø> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Signed-off-by: AiRanthem <zhongtianyun.zty@alibaba-inc.com>
Signed-off-by: AiRanthem <zhongtianyun.zty@alibaba-inc.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants