1
0

feat: 重构配置布局,server.listen/storage/logging + probes.execution 分组

- 新增 server.listen (host/port)、server.storage (dataDir/retention)、
  server.logging 分组
- 新增 probes.execution (maxConcurrentChecks) 分组,替代顶层 runtime
- 旧配置入口 (runtime/logging/server.host/server.port/server.dataDir)
  启动期拒绝
- 更新 types.ts、builder.ts、config-loader.ts 适配新路径
- 更新 probe-config.schema.json、probes.example.yaml、README.md、
  DEVELOPMENT.md
- 补充 config-loader 和 variables 测试覆盖新路径和旧入口拒绝
- 同步 5 个 delta specs 到主规范 (probe-config, config-variables,
  data-retention, probe-engine, runtime-logging)
- 归档 openspec change reorganize-config-layout
This commit is contained in:
2026-05-21 13:54:41 +08:00
parent 5238dbe77d
commit e448cb4654
14 changed files with 614 additions and 376 deletions

View File

@@ -1,24 +1,26 @@
# yaml-language-server: $schema=./probe-config.schema.json
server:
host: "127.0.0.1"
port: 3000
dataDir: "/tmp/probes_data"
listen:
host: "127.0.0.1"
port: 3000
storage:
dataDir: "/tmp/probes_data"
# logging:
# level: "info"
# console:
# level: "info"
# file:
# level: "info"
# path: "/var/log/dial/dial.log"
# rotation:
# size: "50MB"
# frequency: "daily"
# maxFiles: 14
runtime:
maxConcurrentChecks: 20
# logging:
# level: "info"
# console:
# level: "info"
# file:
# level: "info"
# path: "/var/log/dial/dial.log"
# rotation:
# size: "50MB"
# frequency: "daily"
# maxFiles: 14
probes:
execution:
maxConcurrentChecks: 20
defaults:
interval: "30s"