Skip to content

feat(ocap): support multiple providers of a capability type - #50

Merged
kaniini merged 1 commit into
mainfrom
feature/ocap-providers
Aug 11, 2026
Merged

feat(ocap): support multiple providers of a capability type#50
kaniini merged 1 commit into
mainfrom
feature/ocap-providers

Conversation

@kaniini

@kaniini kaniini commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

A published capability's name was both its identity and the only key a consumer could bind to, so exactly one workload could ever satisfy a given name. Separate the two: name stays the implementation's own identity and implements lists the capability types it satisfies, so dev.edera/foo may implement dev.edera/bar alongside other providers.

Selection among them is by priority (higher wins), with provider on a consume pinning one implementation instead. The pin binds late, so a providing workload may restart or move zones without invalidating it.

ObjectCapabilitySpec.receives is replaced by a repeated message field to carry the pin. It is renamed to consumes rather than reusing the name on a new tag: WIRE_JSON compatibility requires a deleted field's name to stay reserved, and protoc forbids reusing a reserved name. Tag 2 and the name receives are both burned.

ObjectCapabilityInfo reports implements/priority for discovery, and DialObjectCapabilityStart carries the pin for direct callers.

A published capability's name was both its identity and the only key a
consumer could bind to, so exactly one workload could ever satisfy a
given name. Separate the two: `name` stays the implementation's own
identity and `implements` lists the capability types it satisfies, so
dev.edera/foo may implement dev.edera/bar alongside other providers.

Selection among them is by `priority` (higher wins), with `provider` on
a consume pinning one implementation instead. The pin binds late, so a
providing workload may restart or move zones without invalidating it.

ObjectCapabilitySpec.receives is replaced by a repeated message field to
carry the pin. It is renamed to `consumes` rather than reusing the name
on a new tag: WIRE_JSON compatibility requires a deleted field's name to
stay reserved, and protoc forbids reusing a reserved name. Tag 2 and the
name `receives` are both burned.

ObjectCapabilityInfo reports implements/priority for discovery, and
DialObjectCapabilityStart carries the pin for direct callers.
@github-actions

Copy link
Copy Markdown

The latest Buf updates on your PR. Results from workflow Buf CI / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedAug 11, 2026, 7:08 PM

@kaniini
kaniini requested a review from azenla August 11, 2026 19:08
@kaniini
kaniini merged commit 0afeba9 into main Aug 11, 2026
2 checks passed
@kaniini
kaniini deleted the feature/ocap-providers branch August 11, 2026 19:17
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