7c1e439c3b
fix: reorder optional params
Deploy API Server / build-and-deploy (push) Has been cancelled
2026-05-23 19:48:06 +08:00
ad0e4f397a
fix: break circular dependency between EventBusService and QueueService
Deploy API Server / build-and-deploy (push) Has been cancelled
2026-05-23 19:47:40 +08:00
99d03bb26c
feat: M0-10 — TaskLog table + task events + retry audit
Deploy API Server / build-and-deploy (push) Failing after 32s
2026-05-23 19:29:08 +08:00
2c6d56bcfc
feat: M0-10 — Task types enum + worker heartbeat + Domain Events for tasks
Deploy API Server / build-and-deploy (push) Successful in 40s
2026-05-23 19:27:46 +08:00
9244db05b4
feat: M0-09 — BullMQ cleanup queue + Domain Events + async COS delete
Deploy API Server / build-and-deploy (push) Successful in 35s
2026-05-23 09:47:30 +08:00
b5a983dc6b
feat: M0-04 Audit — async BullMQ writes + riskLevel + reason + SecurityEvent
Deploy API Server / build-and-deploy (push) Successful in 39s
2026-05-22 23:03:32 +08:00
3fd5f94db5
feat: complete M0-01 — TraceId + BaseService + DomainEvent + SensitiveLogger
Deploy API Server / build-and-deploy (push) Successful in 35s
2026-05-22 22:19:06 +08:00
bced62c8f6
fix: add missing redis client connect call in onModuleInit
...
Deploy API Server / build-and-deploy (push) Successful in 58s
ioredis with lazyConnect: true requires explicit .connect() — without it
the client never connects and isHealthy() always returns false.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-17 23:00:11 +08:00
ca90d34b22
fix: 将 RateLimitService 注入从 StorageService 移到 FilesService
...
Deploy API Server / build-and-deploy (push) Failing after 56s
StorageService 在 @Global StorageModule 中,无法注入 AppModule 的 RateLimitService。
将限流调用上移到 FilesService.requestUploadUrl 中。
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-17 22:50:31 +08:00
6d7cbffc3b
feat: COS 对象存储接入 — CosStorageProvider + FilesModule
...
Deploy API Server / build-and-deploy (push) Failing after 3m0s
- 安装 cos-nodejs-sdk-v5,封装 CosStorageProvider(upload/download/delete/healthCheck)
- 重写 StorageService,新增 createUploadUrl/verifyUpload/getDownloadUrl/deleteObject
- 创建 FilesModule:POST /files/upload-url, POST /files/complete, GET /files/:id, DELETE /files/:id
- UploadedFile 新增 objectKey/bucket 字段
- 对象键格式 {userId}/{YYYYMM}/{sanitizedName}.{ext}
- 接入文件类型校验(ALLOWED_FILE_TYPES)+ 上传限流(10次/小时/用户)
- 配置文件 cos.longde.cloud → zhixi-1259685406 / ap-guangzhou
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-17 22:30:14 +08:00
08f31dd5b6
feat: P0 后端补全 — BullMQ Workers 注册 + 用户 Profile API + 角色权限
...
- AppModule 注册 3 个 BullMQ Workers (AiAnalysis/DocumentImport/Notification)
- Users 模块新增 GET/PATCH /users/me/profile 端点:
- GET 读取 UserProfile (learningIdentity, learningDirection, bio, currentGoal)
- PATCH upsert UserProfile
- GET /users/me 返回 profile + preferences (include join)
- 新增 RolesGuard + @Roles() 装饰器 (UserRole enum)
- QueueModule/QueueService 改进
- 各模块 controller/repository/service 完善
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-17 19:08:07 +08:00
007b56dad5
feat: AI三层架构 + 全局JwtAuthGuard + 12个Repository迁Prisma
...
Deploy API Server / build-and-deploy (push) Successful in 1m0s
- AI: 新三层架构 Provider→Gateway→Workflow(15文件,DeepSeek+MiniMax)
- Auth: 全局JwtAuthGuard + @Public()装饰器白名单路由
- DB: 12个Repository从Map/Array迁到Prisma
- Schema: 新增AiUsageLog、WaitlistEntry模型
- API: /api-docs-json加Basic Auth保护
- 清理: 删除infrastructure/ai、docs/旧文档
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-17 00:39:46 +08:00
35de65e99b
feat: 重构 api-server 为模块化单体架构,接入 MySQL + Redis
...
- 按 BACKEND-PLAN.md 将项目重构为 4 层架构:
config/ -> common/ -> infrastructure/ -> modules/
- 15 个业务模块,遵循 Controller → Service → Repository 分层
- infrastructure: PrismaService / RedisService / QueueService / AiService / StorageService
- common: guards / interceptors / filters / pipes / decorators / dto / types / utils
- Prisma schema 含 27 张表,MySQL 8.0 服务器 db push 成功
- Redis 7 接入: 限流/任务状态/分布式锁/队列预留
- ai-analysis 模块: 每日 50 次限流 + 重复提交锁 + 异步任务状态追踪
- document-import 模块: 异步导入流程 + 进度追踪
- notifications 模块: BullMQ notification 队列预留
- /health 端点实时返回 database + redis 连接状态
- Swagger 注册 15 个 tag,67 个路由全部映射
2026-05-09 18:25:04 +08:00