Giter VIP home page Giter VIP logo

wasmio-2024-demos's Introduction

Wasm I/O 2024 - Demos

This repository contains all samples shown as part of my talk about the WebAssembly Component Model held during Wasm I/O 2024 in Barcelona, Spain.

Both of the following samples have dedicated READMEs to outline how one could build & run them.

You can find the recording of the talk on YouTube here: https://www.youtube.com/watch?v=NFbjQNqWi94.

Extensibility

The extensibility demo illustrates how one could use the WebAssembly Component Model to add extensibility to their own application. By relying on WIT contract, extension developers can use any language - that could be compiled into WebAssembly and packaged as a Wasm Component - and use the canonical ABI provided by the component model.

Composition

The composition demo shows how WebAssembly components can be used to align with the DRY principle. As part of the demo, a WebAssembly Component (HMAC implementation) is being used in a webhook producer (acme-product) which is written in Rust. The same component is used in the webhook consumer (wonka-3rd-party-service) which is written in Python.

wasmio-2024-demos's People

Contributors

mikkelhegn avatar thorstenhans avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

wasmio-2024-demos's Issues

Error while trying to reproduce demo

Thanks for your talk at wasmio!

When trying to reproduce the demo I run into this error:

make build-all-plugins
pushd plugins; \
        pushd uppercase; \
        cargo component build --target wasm32-unknown-unknown --release; \
        mv ./target/wasm32-unknown-unknown/release/uppercase.wasm ../../
~/workspace/wasmio-2024-demos/extensibility/plugins ~/workspace/wasmio-2024-demos/extensibility
~/workspace/wasmio-2024-demos/extensibility/plugins/uppercase ~/workspace/wasmio-2024-demos/extensibility/plugins ~/workspace/wasmio-2024-demos/extensibility
   Compiling uppercase v0.1.0 (/Users/andrew/workspace/wasmio-2024-demos/extensibility/plugins/uppercase)
warning: unused import: `__export_world_plugin_cabi`
  --> src/bindings.rs:44:16
   |
44 | pub(crate) use __export_world_plugin_cabi;
   |                ^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: `#[warn(unused_imports)]` on by default

warning: unused import: `__export_plugin_impl as export`
  --> src/bindings.rs:95:16
   |
95 | pub(crate) use __export_plugin_impl as export;
   |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0433]: failed to resolve: use of undeclared crate or module `wit_bindgen_rt`
   --> src/bindings.rs:110:5
    |
110 |     wit_bindgen_rt::maybe_link_cabi_realloc();
    |     ^^^^^^^^^^^^^^ use of undeclared crate or module `wit_bindgen_rt`
    |
help: there is a crate or module with a similar name
    |
110 |     wit_bindgen::maybe_link_cabi_realloc();
    |     ~~~~~~~~~~~

For more information about this error, try `rustc --explain E0433`.
warning: `uppercase` (lib) generated 2 warnings
error: could not compile `uppercase` (lib) due to 1 previous error; 2 warnings emitted
mv: ./target/wasm32-unknown-unknown/release/uppercase.wasm: No such file or directory
make: *** [build-uppercase] Error 1
[7:51](https://redhat-internal.slack.com/archives/D06S7H40NKG/p1712166674327649)

I suspect it’s because I am on a newer version of cargo-component - but not sure… could be wit-bindgen version too…. so will have to investigate

Just posting here:

  • in case you have any ideas that could help me
  • in case it's something that give others problems too that you might need to fix

Thanks for any help!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.