Skip to content
/ tanour Public

WASM executor for blockchains

License

Notifications You must be signed in to change notification settings

b00f/tanour

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tanour

Tanour is a Contract actor executor for Zarb blockchain.

Features

Standalone and stateless

Tanour can be launched as an independent and standalone process and it has no internal state. Interacting with the Zarb blockchain happens through the set of Provider APIs.

tanour-stateless

Actor model

Contract in Zarb are like Actors in the Actor model.

Each contract actor:

  • Can be instantiated through the instantiate method.
  • Can process the message it receives through process_msg method.
  • Can concurrently send a message to another contract actor through the send_msg method.

These are the only methods that each contract can expose to the outside world.

Storage as file

Storage in Zarb is not a set of key-value pairs, indeed it's a separate file that each contract actor has the read and write access to modify it. This model comes with many advantages. However, there are some disadvantages like difficulty of writing the smart contract and lack supported map data type.

Storage as key-value pairs

storage_map

Storage as file

storage_file

WebAssembly

Contract actor are written in WebAssembly and currently Tanour is using Wasmer to execute the contracts.

Gas metering

TODO

Building

Tanour requires latest stable Rust version to build. You can install Rust through rustup.

In order to use Tanour as a webservice you also need to install Cap'n Proto.

To build the Tanour from the source code, you can follow these commands:

$ git clone https://github.com/zarb/tanour
$ cd tanour

# build in release mode
$ cargo build --release

License

This package is licensed under the MIT License.

About

WASM executor for blockchains

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published