Skip to content

Commit

Permalink
examples: add example running reactor component
Browse files Browse the repository at this point in the history
  • Loading branch information
G4Vi committed Feb 24, 2024
1 parent cc52a98 commit 58f35c9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ target
build.js
node_modules
dist
corpus/01-component-instr-component/wit/deps
8 changes: 8 additions & 0 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,13 @@ component_demo_2:
)
(cd rust/; cargo run -F component-model --example otel-stdout-components ../corpus/02-component-instr-combined/target/wasm32-wasi/debug/final.wasm)

component_demo_3:
#!/bin/bash
set -eou pipefail
(cd corpus/01-component-instr-component; cargo component build)
(mkdir -p corpus/01-component-instr-component/wit/deps/observe)
(cp wit/observe.wit corpus/01-component-instr-component/wit/deps/observe/)
(cd rust/; cargo run -F component-model --example reactor-hello-world-otel-stdout-components ../corpus/01-component-instr-component/target/wasm32-wasi/debug/component_instr_component.wasm)

local_instr instr_path="../wasm-instr/wasm-instr":
for i in test/*.c.wasm; do o=${i%.wasm}; {{ instr_path }} $i > $o.instr.wasm; done

0 comments on commit 58f35c9

Please sign in to comment.