ticket: ready worker runtime followups

This commit is contained in:
Keisuke Hirata 2026-06-26 01:39:23 +09:00
parent 1966ec614d
commit f858e015b1
No known key found for this signature in database
12 changed files with 148 additions and 21 deletions

View File

@ -2,7 +2,7 @@
title: 'Planning Ticket API and UI without queue operations'
state: 'planning'
created_at: '2026-06-23T19:41:51Z'
updated_at: '2026-06-23T19:41:51Z'
updated_at: '2026-06-25T16:38:49Z'
assignee: null
---

View File

@ -4,4 +4,46 @@
LocalTicketBackend によって作成されました。
---
<!-- event: intake_summary author: hare at: 2026-06-25T16:34:15Z -->
## Intake summary
Marked ready by `yoi ticket state`.
---
<!-- event: state_changed author: "yoi ticket" at: 2026-06-25T16:34:15Z from: planning to: ready reason: cli_state field: state -->
## State changed
Marked ready by `yoi ticket state`.
---
<!-- event: state_changed author: "yoi ticket" at: 2026-06-25T16:38:49Z from: ready to: planning reason: cli_state field: state -->
## State changed
State changed to `planning`.
---
<!-- event: decision author: hare at: 2026-06-25T16:38:49Z -->
## Decision
Returned to planning because the ticket is too broad in the current Runtime direction.
Planning Ticket creation from Web UI should not be a direct form-to-file mutation that bypasses Intake. The intended flow likely needs Backend embedded Runtime + Intake Worker first, then Web Intake/Planning UI on top.
Suggested split:
1. Ticket read API / list-detail UI only.
2. Backend embedded Intake Worker on worker-runtime.
3. Web Intake Console / Planning Ticket creation through Intake.
---

View File

@ -1,8 +1,8 @@
---
title: 'Backend内蔵Companion RuntimeとWeb Console MVP'
state: 'planning'
state: 'ready'
created_at: '2026-06-25T11:45:17Z'
updated_at: '2026-06-25T13:25:34Z'
updated_at: '2026-06-25T16:34:16Z'
assignee: null
---

View File

@ -4,4 +4,21 @@
LocalTicketBackend によって作成されました。
---
<!-- event: intake_summary author: hare at: 2026-06-25T16:34:16Z -->
## Intake summary
Marked ready by `yoi ticket state`.
---
<!-- event: state_changed author: "yoi ticket" at: 2026-06-25T16:34:16Z from: planning to: ready reason: cli_state field: state -->
## State changed
Marked ready by `yoi ticket state`.
---

View File

@ -1,8 +1,8 @@
---
title: 'worker-runtimeにFS永続化featureを追加する'
state: 'planning'
state: 'ready'
created_at: '2026-06-25T14:44:02Z'
updated_at: '2026-06-25T14:47:43Z'
updated_at: '2026-06-25T16:34:16Z'
assignee: null
---

View File

@ -4,4 +4,21 @@
LocalTicketBackend によって作成されました。
---
<!-- event: intake_summary author: hare at: 2026-06-25T16:34:16Z -->
## Intake summary
Marked ready by `yoi ticket state`.
---
<!-- event: state_changed author: "yoi ticket" at: 2026-06-25T16:34:16Z from: planning to: ready reason: cli_state field: state -->
## State changed
Marked ready by `yoi ticket state`.
---

View File

@ -1,8 +1,8 @@
---
title: 'worker-runtimeにREST command serverを追加する'
state: 'planning'
state: 'ready'
created_at: '2026-06-25T14:44:02Z'
updated_at: '2026-06-25T14:47:43Z'
updated_at: '2026-06-25T16:34:16Z'
assignee: null
---

View File

@ -4,4 +4,21 @@
LocalTicketBackend によって作成されました。
---
<!-- event: intake_summary author: hare at: 2026-06-25T16:34:16Z -->
## Intake summary
Marked ready by `yoi ticket state`.
---
<!-- event: state_changed author: "yoi ticket" at: 2026-06-25T16:34:16Z from: planning to: ready reason: cli_state field: state -->
## State changed
Marked ready by `yoi ticket state`.
---

View File

@ -1,8 +1,8 @@
---
title: 'worker-runtimeにevent stream serverを追加する'
state: 'planning'
title: 'worker-runtimeにWebSocket event stream serverを追加する'
state: 'ready'
created_at: '2026-06-25T14:44:02Z'
updated_at: '2026-06-25T14:47:43Z'
updated_at: '2026-06-25T16:34:16Z'
assignee: null
---
@ -10,16 +10,16 @@ assignee: null
Runtime command は REST/HTTP でよいが、Worker output / status / transcript update を Backend が追うには observation transport が必要になる。Runtime から Backend へ能動接続する相互型は v0 では採用せず、Backend が Runtime の event stream に接続する形にする。Browser は Runtime event stream に直接接続せず、Backend が proxy / projection する。
この Ticket では `worker-runtime` process に SSE または WebSocket based observation server を追加する。実装時に SSE / WebSocket のどちらを v0 にするか決めてよいが、command API とは分離する。
この Ticket では `worker-runtime` process に WebSocket based observation server を追加する。SSE は将来追加してよいが、v0 の実装対象は Backend-owned WebSocket client が接続する Runtime event stream とする。command API とは分離する。
## 要件
- `worker-runtime``event-stream` または `ws-server` feature を追加する。
- `worker-runtime``ws-server` feature を追加する。
- Feature disabled 時、core library は stream server dependency を強制しない。
- Runtime process が Worker / Runtime events を observation endpoint で公開できる。
- Runtime process が Worker / Runtime events を WebSocket observation endpoint で公開できる。
- Endpoint は少なくとも以下のどちらかを扱う。
- `GET /v1/events?cursor=...`
- `GET /v1/workers/{worker_id}/events?cursor=...`
- `GET /v1/events/ws?cursor=...`
- `GET /v1/workers/{worker_id}/events/ws?cursor=...`
- Event stream は Runtime lib の event bus / event log を元にする。
- Event cursor / event id は Runtime local opaque id とする。
- Reconnect / cursor resume / bounded backlog / unknown cursor の扱いを typed にする。
@ -36,13 +36,13 @@ Runtime command は REST/HTTP でよいが、Worker output / status / transcript
## 受け入れ条件
- `worker-runtime` に optional observation transport feature がある。
- `worker-runtime` に optional `ws-server` feature がある。
- Feature disabled でも `worker-runtime` core が compile できる。
- Runtime process exposes worker/runtime event stream endpoint.
- Runtime process exposes worker/runtime WebSocket event stream endpoint.
- Backend client can reconnect with cursor / last event id semantics at the protocol level.
- Unknown cursor / expired cursor / worker not found are typed errors or stream diagnostics.
- Event stream tests cover at least connect, event delivery, cursor resume, and worker-scoped filtering.
- `cargo test -p worker-runtime --features event-stream` または該当 feature が通る。
- WebSocket event stream tests cover at least connect, event delivery, cursor resume, and worker-scoped filtering.
- `cargo test -p worker-runtime --features ws-server` が通る。
- `cargo check -p yoi` が通る。
- `git diff --check` が通る。
- `nix build .#yoi --no-link` が通る。

View File

@ -4,4 +4,21 @@
LocalTicketBackend によって作成されました。
---
<!-- event: intake_summary author: hare at: 2026-06-25T16:34:16Z -->
## Intake summary
Marked ready by `yoi ticket state`.
---
<!-- event: state_changed author: "yoi ticket" at: 2026-06-25T16:34:16Z from: planning to: ready reason: cli_state field: state -->
## State changed
Marked ready by `yoi ticket state`.
---

View File

@ -1,8 +1,8 @@
---
title: 'RuntimeへProfile/config bundleを同期する'
state: 'planning'
state: 'ready'
created_at: '2026-06-25T15:49:30Z'
updated_at: '2026-06-25T15:51:07Z'
updated_at: '2026-06-25T16:34:16Z'
assignee: null
---

View File

@ -4,4 +4,21 @@
LocalTicketBackend によって作成されました。
---
<!-- event: intake_summary author: hare at: 2026-06-25T16:34:16Z -->
## Intake summary
Marked ready by `yoi ticket state`.
---
<!-- event: state_changed author: "yoi ticket" at: 2026-06-25T16:34:16Z from: planning to: ready reason: cli_state field: state -->
## State changed
Marked ready by `yoi ticket state`.
---