You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Spun off from #1241 (B3+B4 architectural cleanup). The three `CollectionService::new` sites inside `create_node`, `update_node`, and `delete_node` are gone after #1241. The remaining 11 sites in the collection-management RPCs still instantiate the service inline in the daemon layer.
Sites to address
All in `packages/daemon/src/services/node_service.rs`:
The daemon is a thin gRPC adapter (ADR-031). Collection semantics belong in core. Recommended: add thin `collection_ops` functions in `packages/core/src/ops/` (paralleling the existing `node_ops`) so each daemon RPC calls one core function instead of orchestrating `CollectionService` itself.
Do NOT inject a single long-lived `CollectionService` into `NodeServiceImpl` — its `'a` lifetime borrows `node_service`, fighting the borrow checker against the `Arc` field.
Acceptance criteria
Each of the 11 daemon collection RPC bodies delegates to a `collection_ops` function (or equivalent core method) rather than directly constructing `CollectionService`.
`collection_ops` functions live in core (`packages/core/src/ops/collection_ops.rs` or similar), following the same input/output struct pattern as `node_ops`.
No inline collection orchestration remains in the daemon collection RPCs.
`cargo test -p nodespace-core -p nodespace-daemon` and `cargo clippy` pass with no new warnings.
No `#[allow(dead_code)]`, no `#[deprecated]`.
Spun off from #1228 (architectural audit), finding B4 — remainder after #1241.
Activity
malibio commentedon May 30, 2026
Frontend: 132 passed (baseline)
B4 follow-up: fold remaining 11 CollectionService::new daemon sites i…
B4 follow-up: fold remaining 11 CollectionService::new daemon sites i…