From c8877b49a4f2149ca907b17ae7c243b169c270f7 Mon Sep 17 00:00:00 2001 From: Hare Date: Sat, 20 Jun 2026 02:23:35 +0900 Subject: [PATCH] ticket: close plugin component model runtime --- .yoi/tickets/00001KVG0HR96/item.md | 4 +- .yoi/tickets/00001KVG0HR96/resolution.md | 42 +++++++++++++++++ .yoi/tickets/00001KVG0HR96/thread.md | 58 ++++++++++++++++++++++++ 3 files changed, 102 insertions(+), 2 deletions(-) create mode 100644 .yoi/tickets/00001KVG0HR96/resolution.md diff --git a/.yoi/tickets/00001KVG0HR96/item.md b/.yoi/tickets/00001KVG0HR96/item.md index abba5b11..5142a735 100644 --- a/.yoi/tickets/00001KVG0HR96/item.md +++ b/.yoi/tickets/00001KVG0HR96/item.md @@ -1,8 +1,8 @@ --- title: 'Plugin: migrate WASM Tool runtime to WebAssembly Component Model' -state: 'done' +state: 'closed' created_at: '2026-06-19T13:18:58Z' -updated_at: '2026-06-19T17:23:13Z' +updated_at: '2026-06-19T17:23:31Z' assignee: null readiness: 'implementation_ready' risk_flags: ['plugin', 'wasm', 'component-model', 'wit', 'runtime-backend', 'sandbox', 'packaging', 'sdk'] diff --git a/.yoi/tickets/00001KVG0HR96/resolution.md b/.yoi/tickets/00001KVG0HR96/resolution.md new file mode 100644 index 00000000..e0ff72d2 --- /dev/null +++ b/.yoi/tickets/00001KVG0HR96/resolution.md @@ -0,0 +1,42 @@ +## Resolution + +`00001KVG0HR96` を完了しました。 + +実装内容: +- Plugin manifest/runtime metadata に明示的な Component Model runtime (`kind = "wasm-component"`) を追加しました。 +- 既存 raw core-Wasm runtime (`kind = "wasm"`, `abi = "yoi-plugin-wasm-1"`) は明示的に維持しました。 +- `wasmtime::component` による Component Tool execution path を追加しました。 +- Component Tool は既存 ToolRegistry / Worker Tool path を通って実行され、hidden context injection はありません。 +- WIT host imports は権限そのものではなく、Plugin grants が Tool execution / host API use の authority boundary のままです。 +- Component runtime に raw runtime 相当の Wasmtime resource limits を追加し、memory/table/instance/output bound の negative tests を追加しました。 +- WASI fs/network/env は expose していません。 +- `yoi plugin list/show` static inspection は Component runtime metadata を報告し、component artifact を実行しません。 +- WIT files、Component sample authoring sketch、docs/design updates、package/Nix updates を追加しました。 +- JSON-string WIT v1 request/response shape は migration bridge として docs に記録し、structured records は follow-up に deferred としました。 + +主な commit: +- `57bbf14e plugin: implement component model runtime` +- `a705bb3b plugin: bound component model runtime resources` +- `63d7ad78 merge: plugin component model runtime` + +Review: +- r1 は Component runtime resource limit 不足で `request_changes`。 +- Coder が resource limiter / negative tests / docs note を追加。 +- r2 は `approve`。 + +最終 validation: +- `cargo fmt --check` +- `git diff --check HEAD^1..HEAD` +- `cargo check` +- `cargo test -p pod feature::plugin::tests -- --nocapture` +- `cargo test -p manifest plugin -- --nocapture` +- `cargo test -p yoi plugin -- --nocapture` +- `nix build .#yoi --no-link` + +Package impact: +- `nix path-info -S .#yoi`: `112156120` +- `bin/yoi`: `54605944` +- output dir: `53M` + +Validation log: +- `/run/user/1000/yoi/yoi-orchestrator/bash-output/bash-rZDseu.log` \ No newline at end of file diff --git a/.yoi/tickets/00001KVG0HR96/thread.md b/.yoi/tickets/00001KVG0HR96/thread.md index ddfed223..64ccb54a 100644 --- a/.yoi/tickets/00001KVG0HR96/thread.md +++ b/.yoi/tickets/00001KVG0HR96/thread.md @@ -404,3 +404,61 @@ Final state: Implementation was merged into Orchestrator branch at `63d7ad78`, r2 review approved, and final Orchestrator validation passed: `cargo fmt --check`, `git diff --check HEAD^1..HEAD`, `cargo check`, focused Plugin tests for `pod`/`manifest`/`yoi`, and `nix build .#yoi --no-link`. --- + + + +## State changed + +Ticket を closed にしました。 + + +--- + + + +## 完了 + +## Resolution + +`00001KVG0HR96` を完了しました。 + +実装内容: +- Plugin manifest/runtime metadata に明示的な Component Model runtime (`kind = "wasm-component"`) を追加しました。 +- 既存 raw core-Wasm runtime (`kind = "wasm"`, `abi = "yoi-plugin-wasm-1"`) は明示的に維持しました。 +- `wasmtime::component` による Component Tool execution path を追加しました。 +- Component Tool は既存 ToolRegistry / Worker Tool path を通って実行され、hidden context injection はありません。 +- WIT host imports は権限そのものではなく、Plugin grants が Tool execution / host API use の authority boundary のままです。 +- Component runtime に raw runtime 相当の Wasmtime resource limits を追加し、memory/table/instance/output bound の negative tests を追加しました。 +- WASI fs/network/env は expose していません。 +- `yoi plugin list/show` static inspection は Component runtime metadata を報告し、component artifact を実行しません。 +- WIT files、Component sample authoring sketch、docs/design updates、package/Nix updates を追加しました。 +- JSON-string WIT v1 request/response shape は migration bridge として docs に記録し、structured records は follow-up に deferred としました。 + +主な commit: +- `57bbf14e plugin: implement component model runtime` +- `a705bb3b plugin: bound component model runtime resources` +- `63d7ad78 merge: plugin component model runtime` + +Review: +- r1 は Component runtime resource limit 不足で `request_changes`。 +- Coder が resource limiter / negative tests / docs note を追加。 +- r2 は `approve`。 + +最終 validation: +- `cargo fmt --check` +- `git diff --check HEAD^1..HEAD` +- `cargo check` +- `cargo test -p pod feature::plugin::tests -- --nocapture` +- `cargo test -p manifest plugin -- --nocapture` +- `cargo test -p yoi plugin -- --nocapture` +- `nix build .#yoi --no-link` + +Package impact: +- `nix path-info -S .#yoi`: `112156120` +- `bin/yoi`: `54605944` +- output dir: `53M` + +Validation log: +- `/run/user/1000/yoi/yoi-orchestrator/bash-output/bash-rZDseu.log` + +---