Repository navigation
Conversation
KubernetesSandbox.shutdown() deleted the SandboxClaim on every release and the state was persisted afterwards, so the next resume always looked up a claim that no longer existed. K8sHelper.resolveSandboxName() then watched an absent object until the 30s resolution timeout before falling back to a fresh create, which made warm resume unreachable and added a 30s stall to every call after the first. Keep the claim alive across calls (it is the identity pointer the persisted state resumes from) and only close the client connection on release. Reclamation stays with the configured shutdownAfterSeconds lifecycle or an explicit terminate() on the SDK handle. Fail fast when the initial claim GET returns null instead of starting a watch that can never see an event.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
AgentScope-Java Version
2.1.0-SNAPSHOT
Description
Fixes #4251.
KubernetesSandbox.shutdown()deleted theSandboxClaimon every release, and the harness persisted the claim name afterwards. The nextresume()therefore always looked up a claim that no longer existed.K8sHelper.resolveSandboxName()did not treat a null GET as not-found; it started a watch for an absent object and waited the full 30-second resolution timeout before falling back to a fresh create. Warm resume never worked and every call after the first paid the 30-second stall.Changes:
KubernetesSandbox.shutdown()now only closes the client connection. The claim is the identity pointer the persisted state resumes from, so it must outlive one call.K8sHelper.resolveSandboxName()throwsSandboxNotFoundExceptionimmediately when the initial claim GET returns null, instead of watching an absent object.shutdownAfterSeconds(...)lifecycle or an explicitterminate()on the SDK handle; no new option or destruction path is introduced.shutdown()does not callterminate(), and a missing claim fails without waiting for a watch.No
.md/documentation files are changed.Checklist
mvn spotless:applymvn test) — K8s module: 73 passed withKubernetesSerializationCompatTestexcluded because it needs a local~/.kube/config; the remaining failure is environmental, not caused by this changedocs/dev/en/docs/harness/sandbox.md