build: bump sandbox-operator to c9d9fda, carry the lease deadline, retire sandboxdx - #6
Merged
Merged
Conversation
ClaimResult.Deadline is a time.Time upstream now, so the string parse goes; ListedSandbox decodes the index row's deadline as a time too, and the published InventoryEntry carries it so the aggregated read path can stamp the deadline annotation.
The operator's sandboxd.Client now covers GET /v1/info (Info) as well as GET /v1/sandboxes (Sandboxes), so the provider's Lister and the inventory InfoClient run on it directly; ListedSandbox and the private /v1/info decoder had no reason left to exist.
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.
Why
sandbox-operator #5 typed
sandboxd.ClaimResult.Deadlineastime.Timeand added an optionaldeadlinetoInventoryEntry(the aggregated apiserver stamps it as thesandbox.cocoonstack.io/deadlineannotation on synthesized reads); against it this repo no longer built (provider/create.go:121: cannot use res.Deadline (time.Time) as string). sandbox-operator #6 then gavesandboxd.ClientanInfo(GET /v1/info) to pair with its existingSandboxes(GET /v1/sandboxes), which removes the last reason for this repo's ownsandboxdxclient.Change
go get github.com/cocoonstack/sandbox-operator@c9d9fda+go mod tidy→v0.1.2-0.20260817100949-c9d9fdad7acc.Claim.Deadlinetakesres.Deadlinedirectly;parseDeadlineis gone.provider.ListerisSandboxes(ctx) ([]sandboxd.SandboxSummary, error)andinventory.InfoClientisInfo(ctx) (*sandboxd.NodeInfo, error)— both satisfied by*sandboxd.Client, somain.gowires the one pooled client everywhere.provider.ListedSandboxand thesandboxdxpackage (private list +/v1/infodecoders) are deleted; theNodeInfo.Pools → PoolCapacitymapping lives ininventory.NodeInfoSource.LiveSourcepublishes each row's deadline on itsInventoryEntry, sokubectl get sandboxescarries the granted lease end once this node republishes.docs/architecture.md: two packages, nothing on the sandboxd wire reimplemented here.Testing
go build ./...(workspace andGOWORK=off),go vet ./...,go test ./...green;make lintlinux + darwin0 issues;asl ./...clean.TestLiveSandboxesasserts the entry carries the row deadline (and none when the row has none);TestNodeInfoSourcepins theNodeInfo → PoolCapacityflattening that moved out ofsandboxdx.