feat(overlay): 内容块级寻址 + 实例逐步拉起 + 骨干选路 + 组密钥加密(序24–㉛ 累积同步)
代码
- 内容分发块级寻址:新增 src/net/relay/content/{chunker,store,runtime,source,peer,crypto}.ts
- 组密钥(C 档)确定性加密:AES-256-GCM,块 id β′ = sha256(密文) 前 32 hex;双 epoch 过渡窗口
- 实例生命周期:三处 teardown() 不再杀实例(local/remote/leased-spawner);启动认领 + TCP 探活判孤儿
- 骨干选路:jitter 选路 + endpoint-target;relay client/server/wire/identity/directory/rendezvous/switcher 调整
- 工作台 src/web/server.ts、src/worker/relay-tunnel.ts 装配与候选链观测
脚本与测试
- scripts/overlay-{probe,keyring,jitter}.cjs 更新
- 探针新增 OBS-21(每连接候选数)/ OBS-22(teardown 静态守卫 + 认领面)/ OBS-23(组密钥加密)
- 新增 test/{orchestrator-teardown,orchestrator-rehydrate,overlay-content,overlay-jitter}.test.mjs;relay 两例更新
文档
- 新增交接单:覆盖网络-序24-内容分发块级寻址 / 序25-实例逐步拉起 / 序26-骨干稳定选路与加密
- INDEX.md、交接单/README.md、skills/dsh-auto-handoff-chain/SKILL.md 同步
验收(零回归,2026-09-18 08:0x 复核)
- npm test 201 tests / 200 pass / 0 fail / 1 skipped
- overlay-failover-drill --scene all --table 12 PASS / 0 SKIP / 0 FAIL
- overlay-probe --table 23 PASS / 0 SKIP / 0 FAIL (rc=0)
This commit is contained in:
1 parent
04776af4b1
commit
09ce76f3af
38 files changed
+9133
-211
No files matched your search
@@ -326,7 +326,16 @@ export class RemoteSpawner implements Spawner {
|
||||
await this.call(host, 'POST', '/stop', { userId }, randomUUID())
|
||||
}
|
||||
|
||||
/**
|
||||
* 覆盖网络线 序 ㉘ → 单 A(候选 `B`):**取证已是 no-op**(`git show HEAD:` 与工作区逐字相同)
|
||||
* ⇒ 本单**不做语义改动**,只把「退出不停实例」这条约束**固化**成可被机器断言的守卫标记
|
||||
* (防将来被改回去 ⇒ "同一语义三份实现"里最容易被顺手破坏的一份)。
|
||||
*
|
||||
* ⛔ 本函数体里**永远不许**出现向远端下发停止的调用(`test/orchestrator-teardown.test.mjs`
|
||||
* 有动态断言 + 静态 grep 断言)。
|
||||
*/
|
||||
async teardown(): Promise<void> {
|
||||
// ⛔ 退出不停远端实例(guard: teardown-must-not-stop-instances)
|
||||
// 远端实例的寿命长于任何单个 Manager 副本 ⇒ 由 Manager 的归属/租约管理,不在关闭时清。
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user