Commit Graph

5 Commits

Author SHA1 Message Date
hhs
314554ded7 feat: Phase 5.2 - 实现 query 处理逻辑
- 创建可取消的 context 并存储 cancel func
- 获取对话历史并传递给 orchestrator
- 启动 orchestrator.ProcessQuery goroutine 处理查询
- 请求完成后自动清理 cancel func 和活跃请求标记
2026-06-13 16:14:20 +08:00
hhs
19535e6a37 feat: Phase 5.1 - Client 扩展,添加 orchestrator 依赖
- 扩展 Client 结构体,添加 sessionManager、orchestrator、cancelFuncs 字段
- 创建 WSClient 适配器实现 orchestrator.Sender 接口
- 更新 ServeWS 函数签名,接收 orchestrator 参数
- 在 main.go 中初始化 AI 服务和 Orchestrator
2026-06-13 16:13:22 +08:00
hhs
fe4dedec71 feat: WS handler 接入 SessionManager,main.go 注入依赖 + 健康检查获取活跃会话数
Some checks failed
Backend CI / ci (pull_request) Failing after 15s
Frontend CI / ci (pull_request) Has been cancelled
2026-06-13 15:31:15 +08:00
hhs
da87ec776b feat: main.go 接入配置 + graceful shutdown + logger 迁移
- main.go: 接入 config.Load() 替换硬编码 :8080
- main.go: 添加 signal.NotifyContext + http.Server.Shutdown(10s drain)
- main.go: 初始化 Zap 日志,prod 环境切换 Gin release 模式
- ws/handler.go: 所有 log.Printf 替换为 logger.Log 结构化日志
- 修复 .gitignore 排除规则(/server 仅匹配根目录二进制)
- 新增 zap、viper 依赖
2026-06-13 15:18:03 +08:00
hhs
9f876df816 feat: 初始化 Go 后端项目骨架
- 使用 Gin 框架替代原始 net/http,方便调试
- 实现 WebSocket 端点 (/ws),支持 ping/query/config/interrupt 消息
- 实现健康检查 REST 接口 (/api/health)
- 定义协议数据结构 (models)
- 心跳检测(60 秒超时断开)
2026-06-12 17:34:43 +08:00