Back to Spin

Adapters

crates/componentize/adapters/README.md

4.0.01016 B
Original Source

Adapters

The componentize process uses adapters to adapt plain wasm modules to wasi preview 2 compatible wasm components. There are three adapters that are built and stored as wasm binaries in this repository:

  • The upstream wasi preview1 adapters for both commands and reactors for use with newer versions of wit-bindgen (v0.5 and above).
  • A modified adapter that has knowledge of Spin APIs for use with v0.2 of wit-bindgen which has a different ABI than newer wit-bindgen based modules.
    • This is currently built using commit 603fb3e on the github.com/rylev/wasmtime fork of wasmtime.
    • You can see a diff between the upstream wasmtime 18.0.1 compatible adapter and this custom adapter here.