Tairitsu - Generic WASM Component Runtime Engine
This framework provides Docker-like image/container mechanisms for running WASM components. It does not prescribe any specific WIT interface - users define their own.
Architecture
- [
Image] - Represents a compiled WASM component (like a Docker image) - [
Container] - Represents a running instance of an Image (like a Docker container) - [
Registry] - Manages multiple Images and Containers (like a Docker daemon) - [
WitInterface] - User-defined WIT interface trait - [
ContainerBuilder] - Builder pattern for creating containers with custom WIT bindings
Quick Start
use ;
use Bytes;
// 1. Define your WIT interface (use wit-bindgen to generate bindings)
// wit-bindgen generates your WIT code...
// 2. Create a WASM image
let wasm_binary = read?;
let image = new?;
// 3. Create container (user handles WIT binding)
let container = builder?
.with_guest_initializer?
.build?;
Helper Macros
use wit_interface;
// Automatically generate WIT interface code
wit_interface!