feat(runtime): /actions /mcp 两域 handler 体抽出 — ADR-0076 D11 步骤③ PR-9 (#2462) - #3568
Merged
Conversation
…6 D11 step ③ PR-9 (#2462) The deep-coupling batch rides the PR-8 subsystem out: - domains/actions.ts: ADR-0066 D4 gate + ADR-0104 param contract on actionExec.*; the env pre-resolution block becomes two deps seams — getDefaultEnvironmentId + resolveProjectKernelObjectQL (the ADR-0006 Phase-5 direct-caller kernel swap; the this.kernel write side effect stays dispatcher-owned). The redundant leading/trailing-slash regex (CodeQL redos twin flagged in #2462) drops for split+filter. - domains/mcp.ts: transport + /mcp/skill + OAuth resource-metadata + the principal-bound bridge; legacy /mcp/skill-before-/mcp precedence reproduced with ordered entries incl. '?' forms. buildMcpBridge kept as a public thin delegate for direct callers (tests). - Statics gotcha round 2: HttpDispatcher.isMcpEnabled — extracted body referenced the class static; inlined to isMcpServerEnabled() at both sites and the wrapper dropped. - The authz-conformance identity pin for buildMcpBridge(context) follows the body: discover file/re/key now point at domains/mcp.ts. Verified: runtime 649, http-conformance 41, dogfood 351, full build green. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
Contributor
📓 Docs Drift CheckThis PR changes 2 package(s): 18 hand-written doc(s) reference the affected code and may need an implementation-accuracy re-verification:
|
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
动机(#2462 D11 步骤③,深耦合批第二刀)
PR-8 子系统就位后,
/actions与/mcp抽体成为机械刀。dispatch() 的 if 链至此只剩/meta与/data。改动
domains/actions.ts:ADR-0066 D4 权限门 + ADR-0104 参数契约跑在 actionExec.* 上。env 预解析段收敛为两个新 deps 缝——getDefaultEnvironmentId+resolveProjectKernelObjectQL(ADR-0006 Phase 5 直调方 kernel 交换;this.kernel写入副作用留 dispatcher)。顺删冗余首尾斜杠正则(ADR-0076: remaining objectql/protocol layering work (cross-repo window) #2462 预扫的 CodeQL redos 孪生),split+filter 已覆盖。domains/mcp.ts:JSON-RPC transport +/mcp/skill下载 + OAuth resource-metadata + principal-bound 工具桥全家。/mcp/skill先于/mcp的匹配优先级用有序注册项复刻(含?变体共四条)。buildMcpBridge留公共薄委托给直调方(测试)。HttpDispatcher.isMcpEnabled被抽出体引用——内联为isMcpServerEnabled()双站点,包装删除。buildMcpBridge(context)的 discover file/re/key 指向domains/mcp.ts(pin 语义不变)。验证
runtime 649 绿;http-conformance 41 绿;dogfood 全套 351 绿;全仓 build 绿。零行为变化。
关联 #2462。剩最后一刀:/meta + /data(终刀)→ catch-all 退役 → 解锁步骤①。
🤖 Generated with Claude Code