Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

WasmEdge for Rust Storage Extension

The WasmEdge (formerly SSVM) is a high performance WebAssembly runtime optimized for server side applications. This project provides support for storage access with Rust native storage library.

Getting Started

Prepare the environment

Use our docker image (Recommanded)

Our docker image is based on ubuntu 20.04.

$ docker pull wasmedge/wasmedge

Or setup the environment manually

Please notice that WasmEdge-storage requires cmake>=3.11

# Tools and libraries
$ sudo apt install -y \
	software-properties-common \
	cmake \

# WasmEdge supports both clang++ and g++ compilers
# You can choose one of them for building this project
$ sudo apt install -y gcc g++
$ sudo apt install -y clang

Get WasmEdge-storage Source Code

$ git clone --recursive
$ cd WasmEdge-storage
$ git checkout 0.8.1

Prepare Machine with RocksDB

Follow Steps to prepare a machine with RocksDB.

Install Rust and Cargo

$ curl -sSf | sh
$ source $HOME/.cargo/env

Build WasmEdge-storage

WasmEdge-storage depends on WasmEdge-Core, you have to prepare WasmEdge-Core before you build WasmEdge-storage. We provides two options for setting up the WasmEdge-Core:

Create and Enter the Build Folder

# After pulling our WasmEdge docker image
$ docker run -it --rm \
    -v <path/to/your/WasmEdge-storage/source/folder>:/root/WasmEdge-storage \
(docker)$ cd /root/WasmEdge-storage
(docker)$ mkdir -p build && cd build

Option 1. Use built-in CMakeLists to get WasmEdge-Core (Recommended)

(docker)$ cmake -DCMAKE_BUILD_TYPE=Release .. && make

Option 2. Use specific version of WasmEdge-Core by giving WASMEDGE_CORE_PATH

(docker)$ cmake -DWASMEDGE_CORE_PATH=<path/to/WasmEdge/source> -DCMAKE_BUILD_TYPE=Release .. && make

The shared library build/lib/ is the C API to create the wasmedge-storage import object. The header build/include/wasmedge-storage.h is the header of the shared library. The static library build/lib/libwasmedgeHostModuleWasmEdgeStorage.a is for executables linking in CMake.