first commit
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
# ADR-003:分层架构与设计模式
|
||||
|
||||
## 状态
|
||||
已接受
|
||||
|
||||
## 采用模式
|
||||
- Application Factory:`create_app`
|
||||
- Strategy:`ModelProvider`
|
||||
- Factory:`ProviderFactory`
|
||||
- Repository:数据库访问
|
||||
- Service Layer:能力探测、测试计划、执行、报告
|
||||
- Dependency Injection:FastAPI Depends
|
||||
- Gateway:DatasetGateway
|
||||
|
||||
`ProviderFactory` 复用同一数据库会话读取持久化的 `target`/`judge` 配置;缺少对应记录时才读取 `Settings` 中的环境变量。连接检查和后台运行走同一工厂;能力探测只作为运行内部阶段,避免配置与执行分叉。
|
||||
|
||||
## 边界
|
||||
不引入复杂领域事件、CQRS、事件溯源或微服务。当前规模下这些会增加维护成本,不能直接提升核心测试能力。
|
||||
Reference in New Issue
Block a user