Expand description
This crate contains the binaries of three WebAssembly modules:
WASI_SNAPSHOT_PREVIEW1_REACTOR_ADAPTER
WASI_SNAPSHOT_PREVIEW1_COMMAND_ADAPTER
WASI_SNAPSHOT_PREVIEW1_PROXY_ADAPTER
These three modules bridge the wasip1 ABI to the wasip2 ABI of the component model.
They can be given to the wit_component::ComponentEncoder::adapter
method, using the WASI_SNAPSHOT_PREVIEW1_ADAPTER_NAME
, to translate a
module from the historical WASM ABI to the canonical ABI.
Constants§
- WASI_
SNAPSHOT_ PREVIE W1_ ADAPTER_ NAME - The name of the adapters in this crate, which may be provided to
wit_component::ComponentEncoder::adapter
. - WASI_
SNAPSHOT_ PREVIE W1_ COMMAND_ ADAPTER - The “command” adapter extends the “reactor” adapter and additionally
exports a
run
function entrypoint. - WASI_
SNAPSHOT_ PREVIE W1_ PROXY_ ADAPTER - The “proxy” adapter provides implements a HTTP proxy which is more restricted than the “reactor” adapter adapter, as it lacks filesystem, socket, environment, exit, and terminal support, but includes HTTP handlers for incoming and outgoing requests.
- WASI_
SNAPSHOT_ PREVIE W1_ REACTOR_ ADAPTER - The “reactor” adapter provides the default adaptation from preview1 to preview2.