Skip to content

P3 - #89

Merged
scothis merged 4 commits into
componentized:mainfrom
scothis:p3
Oct 9, 2026
Merged

P3#89
scothis merged 4 commits into
componentized:mainfrom
scothis:p3

Conversation

@scothis

@scothis scothis commented Oct 9, 2026

Copy link
Copy Markdown
Member

All methods touching a network socket are now async, and using the wasi p3 interfaces.

Dropping wasi:keyvalue was required as the component model currently does not fully support calling a async method from a sync method. wasi:keyvalue support will be restored once the component model restriction is resolved, or wasi:keyvalue's api becomes async (WebAssembly/wasi-keyvalue#68). Until then, wasmcloud:keyvalue has an interface that is substantially similar and already async.

Added addition commands to fully implement wasmcloud:keyvalue:

  • expire
  • expireat
  • hexpire
  • hexpireat

The cli component is now built with wasm32-unknown-unknown, dropping wasm32-wasip2.

The all wrap network calls, which themselves will be async.

wasi:keyvalue is entierly sync, so wit_bindgen::block_on is used.

Signed-off-by: Scott Andrews <scott@andrews.me>
Signed-off-by: Scott Andrews <scott@andrews.me>
Signed-off-by: Scott Andrews <scott@andrews.me>
- wasi:http@0.2 -> 0.3
- wasi:keyvalue -> wasmcloud:keyvalue
- add expire, expireat, hexpire, hexpireat operations

Dropping wasi:keyvalue was required as the component model currently
does not fully support calling a async method from a sync method. This
restriction will be reverted once the component model restriction is
resolved, or wasi:keyvalue's api becomes async. Until then, wasmcloud
has an interface that is substantially similar and already async.

Signed-off-by: Scott Andrews <scott@andrews.me>
@scothis
scothis merged commit ed7996d into componentized:main Oct 9, 2026
3 checks passed
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.

1 participant