[GH-ISSUE #8429] refactor: unify capability composition and retryable resource ownership #6602

Closed
opened 2026-11-01 21:12:36 +00:00 by bsakaguchi · 0 comments
Owner

Originally created by @gensokyo-dev on GitHub (Nov 1, 2026).
Original GitHub issue: https://github.com/morluto/rea/issues/8429

Before submitting

  • I searched related issues and PRs, including #740, #2016 and #3137.
  • I reviewed the contribution scope; this is an existing-capability architecture increment.
  • This report includes no credentials or private target data.

Decision needed

Complete a bounded #740 T3/T5/T7 increment: derive production service creation, availability facts and retryable cleanup from typed capability declarations, and reuse source-owned provider/operation bindings in catalog generation.

Context and evidence

Source audit at main 6e9ee97a69cb16c7150d8b550e705cba055ee4f0: createServer separately enumerates constructors, registration, availability and close callbacks. WASM/EVM/APK-signature descriptors bind selected contracts/factories but do not drive these ownership lists. Frida/Cutter/GDB/Rizin construction is repeated in CLI/MCP. Catalog provider-to-operation bindings are maintained separately in scripts/lib/catalog-builders.mjs.

These are source-derived maintenance findings. No real-provider failure is claimed. #740 already delivered investigation ownership, shared factories, optional failure isolation, many directory migrations and boundary/discovery guards; reuse them.

Expected interaction with targets

Existing caller-selected files/captures and explicitly selected provider actions only. This increment adds no operation or target authority. Registration must not launch an engine, acquire targets, install tools or probe networks.

Boundary details

Preserve named contracts, CLI/MCP outputs, complete Evidence/provenance/Unknown history, provider selection, selected environment, optional-peer isolation and existing failure semantics. Distinguish connection-owned, caller-owned/shared optional providers and one-shot CLI lifetimes. Keep the BinarySession admission/reset/transition barrier intact; its internal decomposition is separate work. No dynamic plugin loader, multi-package split, universal JSON operation port, cache, daemon or new approval flow.

Success criteria

  • A created host-owned capability registers its close capability at the same owning boundary; there is no independent provider close list. Concurrent shutdown joins; successful peers stay released while failed cleanup remains retryable.
  • Typed domain interfaces and shared fresh factories serve CLI/MCP. Dynamic availability remains observed facts rather than static catalog claims.
  • Source provider/operation declarations feed both runtime composition and catalog generation, with unchanged canonical catalog semantics and no eager schema/provider graph in lightweight startup.
  • Exact public CLI/MCP and domain regressions cover lifecycle/cancellation/partial cleanup, overrides/host support, deferred startup and source-boundary protection.
  • Bounded real multi-domain before/after workflows and actual local Codex CLI terra/high runs retain full-result/checkpoint oracles and honest cost/coverage reporting. CI and actionable review findings are resolved before merge.

References

Parent #740; prior module pilot #2016; investigation lifetime #8347 / #8361. External-module distribution remains #3137 and is outside this increment.

Originally created by @gensokyo-dev on GitHub (Nov 1, 2026). Original GitHub issue: https://github.com/morluto/rea/issues/8429 ### Before submitting - [x] I searched related issues and PRs, including #740, #2016 and #3137. - [x] I reviewed the contribution scope; this is an existing-capability architecture increment. - [x] This report includes no credentials or private target data. ### Decision needed Complete a bounded #740 T3/T5/T7 increment: derive production service creation, availability facts and retryable cleanup from typed capability declarations, and reuse source-owned provider/operation bindings in catalog generation. ### Context and evidence Source audit at main `6e9ee97a69cb16c7150d8b550e705cba055ee4f0`: `createServer` separately enumerates constructors, registration, availability and close callbacks. WASM/EVM/APK-signature descriptors bind selected contracts/factories but do not drive these ownership lists. Frida/Cutter/GDB/Rizin construction is repeated in CLI/MCP. Catalog provider-to-operation bindings are maintained separately in `scripts/lib/catalog-builders.mjs`. These are source-derived maintenance findings. No real-provider failure is claimed. #740 already delivered investigation ownership, shared factories, optional failure isolation, many directory migrations and boundary/discovery guards; reuse them. ### Expected interaction with targets Existing caller-selected files/captures and explicitly selected provider actions only. This increment adds no operation or target authority. Registration must not launch an engine, acquire targets, install tools or probe networks. ### Boundary details Preserve named contracts, CLI/MCP outputs, complete Evidence/provenance/Unknown history, provider selection, selected environment, optional-peer isolation and existing failure semantics. Distinguish connection-owned, caller-owned/shared optional providers and one-shot CLI lifetimes. Keep the BinarySession admission/reset/transition barrier intact; its internal decomposition is separate work. No dynamic plugin loader, multi-package split, universal JSON operation port, cache, daemon or new approval flow. ### Success criteria - A created host-owned capability registers its close capability at the same owning boundary; there is no independent provider close list. Concurrent shutdown joins; successful peers stay released while failed cleanup remains retryable. - Typed domain interfaces and shared fresh factories serve CLI/MCP. Dynamic availability remains observed facts rather than static catalog claims. - Source provider/operation declarations feed both runtime composition and catalog generation, with unchanged canonical catalog semantics and no eager schema/provider graph in lightweight startup. - Exact public CLI/MCP and domain regressions cover lifecycle/cancellation/partial cleanup, overrides/host support, deferred startup and source-boundary protection. - Bounded real multi-domain before/after workflows and actual local Codex CLI terra/high runs retain full-result/checkpoint oracles and honest cost/coverage reporting. CI and actionable review findings are resolved before merge. ### References Parent #740; prior module pilot #2016; investigation lifetime #8347 / #8361. External-module distribution remains #3137 and is outside this increment.
bsakaguchi 2026-11-01 21:12:36 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#6602
No description provided.