Skip to content

[WIP]feat: support inplace CPU resize for warm pool sandboxes#228

Open
PersistentJZH wants to merge 1 commit intoopenkruise:masterfrom
PersistentJZH:feat/support-inplace-resize-cpu
Open

[WIP]feat: support inplace CPU resize for warm pool sandboxes#228
PersistentJZH wants to merge 1 commit intoopenkruise:masterfrom
PersistentJZH:feat/support-inplace-resize-cpu

Conversation

@PersistentJZH
Copy link
Copy Markdown
Contributor

Ⅰ. Describe what this PR does

support inplace CPU resize for warm pool sandboxes, both support for e2b sandbox claim api and sandbox claim crd.

Ⅱ. Does this pull request fix one issue?

#68

Ⅲ. Describe how to verify it

Ⅳ. Special notes for reviews

@kruise-bot
Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:

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

@PersistentJZH PersistentJZH force-pushed the feat/support-inplace-resize-cpu branch from 767e305 to 1d13c3b Compare March 29, 2026 09:58
agentsapiv1alpha1.PodLabelTemplateHash: revision,
}
if len(patchSpec.Containers) == 0 {
return fmt.Sprintf(`{"metadata":{"annotations":%s,"labels":%s}}`, utils.DumpJson(annotations), utils.DumpJson(labels))

Check failure

Code scanning / CodeQL

Potentially unsafe quoting Critical

If this
JSON value
contains a double quote, it could break out of the enclosing quotes.
@PersistentJZH PersistentJZH force-pushed the feat/support-inplace-resize-cpu branch from 1d13c3b to b3b25d4 Compare March 29, 2026 10:07
Signed-off-by: PersistentJZH <zhihao.kan17@gmail.com>
@PersistentJZH PersistentJZH force-pushed the feat/support-inplace-resize-cpu branch from b3b25d4 to 87510f7 Compare March 29, 2026 10:12
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 29, 2026

Codecov Report

❌ Patch coverage is 76.86375% with 90 lines in your changes missing coverage. Please review.
✅ Project coverage is 63.60%. Comparing base (59abb93) to head (87510f7).

Files with missing lines Patch % Lines
pkg/utils/inplaceupdate/inplace_update.go 49.55% 44 Missing and 13 partials ⚠️
pkg/sandbox-manager/infra/sandboxcr/claim.go 88.46% 16 Missing and 11 partials ⚠️
pkg/servers/e2b/create.go 20.00% 3 Missing and 1 partial ⚠️
pkg/servers/e2b/models/extensions.go 92.85% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #228      +/-   ##
==========================================
+ Coverage   62.46%   63.60%   +1.14%     
==========================================
  Files         106      106              
  Lines        6855     7213     +358     
==========================================
+ Hits         4282     4588     +306     
- Misses       2301     2326      +25     
- Partials      272      299      +27     
Flag Coverage Δ
unittests 63.60% <76.86%> (+1.14%) ⬆️

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

☔ View full report in Codecov by Sentry.
📢 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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants