Skip to content

fix(cleanup): 第三轮收口——#2135 全四项 / #2136 P0·P1 / #2120 切片2·3 / #2124 文档 - #2145

Merged
DeliciousBuding merged 4 commits into
masterfrom
chore/cleanup-round-3
Aug 31, 2026
Merged

fix(cleanup): 第三轮收口——#2135 全四项 / #2136 P0·P1 / #2120 切片2·3 / #2124 文档#2145
DeliciousBuding merged 4 commits into
masterfrom
chore/cleanup-round-3

Conversation

@DeliciousBuding

Copy link
Copy Markdown
Collaborator

内容(4 个 commit)

  1. fix(clock) [可靠性] 时间/TTL 纪律审计(过期边界/时钟一致性/窗口矛盾) #2135 F1-F4:hub jwtutil 两处解析补 jwt.WithLeeway(30s)(与 capability/edge 对齐,测试改 -31s + 新增 -10s 用例);edge journal retention 7d→24h(与 run 终态 TTL 对齐);tokenRefreshLead 1m→2m;WSReadTimeout 60s→65s(pong-miss 先于 read 超时触发,metrics 不丢)。
  2. fix(api) [后端] API 分页契约审计(参数面/语义一致性/截断暴露) #2136 P0/P1:ListCustomAgentsByOwner 补 MaxPageLimit 硬上限;documents repo 上限 200→500 对齐 API 声明。新增 505/501 行 sqlite 回归测试。
  3. chore(security) [安全] 日志敏感数据审计(hub+edge 秘密本体泄漏面) #2120 切片 2/3:新增 pkg/logmask(SensitiveKey/Attr/Value + 单测);AGENTS.md §9 固化日志纪律。切片 1 已由 fix(security): Edge dispatch 非成功响应日志摘要化(#2120 切片 1) #2121 交付。
  4. docs(deploy) [安全] hub+edge 配置面审计(默认值风险/文档缺口/命名一致性) #2124 切片 3:05-deployment.md 新增「配置面索引」(hub 8 组 + edge 7 组,含 AGENTHUB_EDGE_SHUTDOWN_TIMEOUT);edge README 补 4 行;doc-ssot 200 行预算内。

本地验证

  • make test 0 FAIL、go vet ./...(hub/edge/pkg)、doc SSOT、sleep-ratchet、git diff --check
  • -race:jwtutil/ws/repository/hub/pkg 全绿

合入后

DeliciousBuding and others added 4 commits August 31, 2026 21:58
…F1-F4)

F1:hub jwtutil 两处 ParseWithClaims 补 jwt.WithLeeway(30s),与
capability token(tokendance.go)和 edge validate 对齐;过期测试改 -31s
并新增 -10s leeway 内接受用例。
F2:edge delivery journal retention 7d→24h,与 run 终态清理 TTL 对齐,
避免 journal 比派生源 run 活得久导致孤儿重放。
F3:tokenRefreshLead 1min→2min,覆盖 Edge/Hub 时钟偏移;测试随改。
F4:WSReadTimeout = 2×Heartbeat + PingTimeout(65s),pong-miss 检测先于
read 超时触发以保留 metrics 信号;常量测试同步。

Co-authored-by: Cursor <cursor@vectorcontrol.tech>
… P0/P1)

P0:ListCustomAgentsByOwner 原无 LIMIT,加 config.MaxPageLimit 硬上限
(其余审计列出的 contacts/requests/reactions/devices 经复核已被 #2105 覆盖)。
P1:documents repo 上限 200 → config.MaxPageLimit=500,与 API 层声明一致。
新增 505/501 行 sqlite 上限回归测试。truncated/hasMore 信号与搜索/agent-team
分页迁移属审计 P2 建议,本 PR 不覆盖(issue 留开)。

Co-authored-by: Cursor <cursor@vectorcontrol.tech>
切片2:pkg/logmask 提供 SensitiveKey/Attr/Value,对 token/secret/
authorization/api_key 等字段统一打 ***;带单测。
切片3:AGENTS.md §9 固化「日志只打标识符不打本体,新打点走
pkg/logmask」纪律。切片1 已由 #2121(body_summary)交付。

Co-authored-by: Cursor <cursor@vectorcontrol.tech>
05-deployment.md 新增「配置面索引」节(hub 8 组 + edge 7 组,含
本批新增的 AGENTHUB_EDGE_SHUTDOWN_TIMEOUT);edge-server/README.md
补 4 行。doc-ssot 门禁通过(05-deployment 200 行预算内)。

Co-authored-by: Cursor <cursor@vectorcontrol.tech>
@coderabbitai

coderabbitai Bot commented Aug 31, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 18dfe1d8-3f6b-4ef2-a635-6a5ba342eb5d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant