Skip to content

contract: neutralize asset-cache names, drop gVisor runsc_path (in-tree)#336

Open
Davanum Srinivas (dims) wants to merge 1 commit into
agent-substrate:mainfrom
dims:pluggable/publish-ateom-contract
Open

contract: neutralize asset-cache names, drop gVisor runsc_path (in-tree)#336
Davanum Srinivas (dims) wants to merge 1 commit into
agent-substrate:mainfrom
dims:pluggable/publish-ateom-contract

Conversation

@dims

@dims Davanum Srinivas (dims) commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Two in-tree cleanups to the atelet to ateom contract. There is no package move in this PR.

Companion to #332 (open the sandboxClass enum) and #333 (declarative WorkerPool pod shape).

What changed

  1. Name the asset cache for what it holds, not for gVisor. RunSCBinaryPath becomes CachedAssetPath and ValidateRunscHash becomes ValidateAssetHash. The cache holds any backend's content addressed asset, not just gVisor's runsc. The on disk runsc-<sha> filename is left unchanged on purpose, because existing snapshots embed that absolute path. No behavior change.
  2. Drop the gVisor specific runsc_path proto field (field 4, now reserved) from RunWorkload, Checkpoint, and Restore. gVisor reads its binary from runtime_asset_paths["runsc"] like every other backend. The wire contract now has zero backend specific fields.

What is no longer here

An earlier revision of this PR also relocated the contract to pkg/ (ateompb and ateompath) so an out of tree backend could go get it. That commit is dropped. The ateom API is a private, first party, in repo seam, so a public out of tree contract is not wanted. In repo backends import the contract from internal/ directly. The public plugin contract for Agent Substrate is the atelet API, not the ateom API.

Verified locally: go build ./... and go test on the affected packages pass.

@BenTheElder

Copy link
Copy Markdown
Collaborator

BTW I was chatting with Tim Hockin (@thockin) about this and one key suggestion was that we might wind up with atelet as the extension mechanism. Undecided I think ...

@dims Davanum Srinivas (dims) force-pushed the pluggable/publish-ateom-contract branch from 1913f48 to 2e59f04 Compare June 26, 2026 21:45
@dims

Copy link
Copy Markdown
Collaborator Author

BTW I was chatting with Tim Hockin (@thockin) about this and one key suggestion was that we might wind up with atelet as the extension mechanism. Undecided I think ...

ACK Benjamin Elder (@BenTheElder) some of what i am doing is still useful to get rid of gvisor-isms i think. I am ok with going to atelet and have that conversation and the shape of it. I want to make sure what we have now is pluggable as is as well. it won't stop us from switching over when we decide to.

@dims Davanum Srinivas (dims) changed the title [WIP] contract: publish atelet↔ateom under pkg/, neutralize names, drop runsc_path contract: publish atelet↔ateom under pkg/, neutralize names, drop runsc_path Jun 26, 2026
@dims Davanum Srinivas (dims) marked this pull request as ready for review June 26, 2026 21:58
@dims Davanum Srinivas (dims) force-pushed the pluggable/publish-ateom-contract branch from 2e59f04 to 0df7eff Compare June 26, 2026 22:06
@BenTheElder

Copy link
Copy Markdown
Collaborator

Ack ... I'm not sure we should publish to pkg/, given the guidelines for that ...

…ree)

Two in-tree cleanups to the atelet<->ateom contract; no package relocation.

- 5a: rename the asset-cache symbols away from runsc (RunSCBinaryPath ->
  CachedAssetPath, ValidateRunscHash -> ValidateAssetHash) so the cache is
  named for what it holds (any backend's assets), not gVisor's runsc.
- B4: drop the gVisor-specific runsc_path proto field + runscPathFor; gVisor
  reads runtime_asset_paths like every other backend, leaving the wire
  contract with zero backend-specific fields.

The contract stays under internal/ (ateompb + ateompath). An earlier revision
relocated it to pkg/ to publish a go-gettable SDK; that is dropped -- the ateom
API is private (a first-party / in-repo seam), so a public out-of-tree contract
is not wanted. In-repo backends import it from internal/ directly.
@dims Davanum Srinivas (dims) force-pushed the pluggable/publish-ateom-contract branch from 0df7eff to d6576eb Compare June 28, 2026 00:51
@dims Davanum Srinivas (dims) changed the title contract: publish atelet↔ateom under pkg/, neutralize names, drop runsc_path contract: neutralize asset-cache names, drop gVisor runsc_path (in-tree) Jun 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants