| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| data | ||
| prisma | ||
| scripts | ||
| sql | ||
| src | ||
| tests | ||
| .dockerignore | ||
| .env.example | ||
| .gitignore | ||
| .swcrc | ||
| Dockerfile | ||
| jest.config.cjs | ||
| nest-cli.json | ||
| package.json | ||
| tsconfig.build.json | ||
| tsconfig.json | ||
| tsconfig.typecheck.json |
2026-08-29 生产六轮实测(endo_no_rct,72,769 行,全部在生产 RDS 上跑): 配置 耗时 相对基线 无索引 + 4MB (冷) 18:43 无索引 + 4MB (暖) 17:33 ← 基线;冷暖只差 6%,缓存不是主因 无索引 + 256MB (暖) 11:37 −34% 无索引 + 256MB (暖,复现) 12:12 −30% 有索引 + 4MB (暖) 16:42 −5% ← 噪声内,索引已从生产撤除 有索引 + 128MB (暖) 14:47 −16% ← 128MB 只吃到一半收益⭐ 取 256MB:收益对取值很敏感,128→256 还差一倍。原本按「溢出只有 4 批、 内存用量 8MB」推断 128MB 够用,实测否定了这个推断。⛔ 事务级 SET LOCAL,不能全局调:work_mem 是每个排序/哈希节点的上限,不是每连接。 生产 RDS 约 7GB 内存,全局设大值遇上并发排序会吃穿。SET LOCAL 出事务自动还原, Web API 连接不受影响;场景查询串行,同一时刻只有一条,峰值可控。⛔ 别再加信号码部分索引:测试机与生产都测过,生产 −5% 落在噪声里 (同配置两次测量本身差 6%),不值得引入一个 Prisma 管不到的索引。 tests/recall-future-return-visit-gate.spec.ts 的 SQL 捕获桩补 $transaction/$executeRaw。 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| data | Loading commit data... | |
| prisma | Loading commit data... | |
| scripts | Loading commit data... | |
| sql | Loading commit data... | |
| src | Loading commit data... | |
| tests | Loading commit data... | |
| .dockerignore | Loading commit data... | |
| .env.example | Loading commit data... | |
| .gitignore | Loading commit data... | |
| .swcrc | Loading commit data... | |
| Dockerfile | Loading commit data... | |
| jest.config.cjs | Loading commit data... | |
| nest-cli.json | Loading commit data... | |
| package.json | Loading commit data... | |
| tsconfig.build.json | Loading commit data... | |
| tsconfig.json | Loading commit data... | |
| tsconfig.typecheck.json | Loading commit data... |