Commit Graph

5 Commits

Author SHA1 Message Date
hailin 747e4ae8ef refactor(mpc-system): migrate to party-driven architecture with PartyID-based routing
- Remove Address field from PartyEndpoint (parties connect to router themselves)
- Update K8s Discovery to only manage PartyID and Role labels
- Add Party registration and SessionEvent protobuf definitions
- Implement PartyRegistry and SessionEventBroadcaster domain logic
- Add RegisterParty and SubscribeSessionEvents gRPC handlers
- Prepare infrastructure for party-driven MPC coordination

This is the first phase of migrating from coordinator-driven to party-driven
architecture following international MPC system design patterns.
2025-12-05 08:11:28 -08:00
Developer f9deca5df0 feat(admin-service): 增强移动端版本上传功能
- 添加 APK/IPA 文件解析器自动提取版本信息
- 支持从安装包自动读取 versionName 和 versionCode
- 添加 adbkit-apkreader 依赖解析 APK 文件
- 添加 plist 依赖解析 IPA 文件
- 优化上传接口支持自动填充版本信息

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-03 02:39:36 -08:00
Developer 8a57013596 feat(admin-service): 实现完整的移动端版本管理和升级服务
- 添加版本CRUD API:list, get, update, delete, toggle
- 添加文件上传支持:APK/IPA文件上传并计算SHA256校验
- 新增移动端专用API endpoint: /api/app/version/check
- 修复deploy.sh自调用权限问题(使用绝对路径)
- 添加完整的技术文档 APP_UPGRADE_SERVICE.md

新增文件:
- MobileVersionController: 移动端兼容的版本检查接口
- FileStorageService: 文件上传和存储服务
- CQRS handlers: ListVersions, GetVersion, UpdateVersion, DeleteVersion, ToggleVersion, UploadVersion

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-02 21:31:36 -08:00
Developer 3385997b86 refactor(admin-service): 完全按DDD架构重构,添加值对象层
值对象层 (Value Objects):
- VersionCode: 整数版本号,支持比较操作
- VersionName: 语义化版本格式 (major.minor.patch)
- BuildNumber: 构建号验证 (字母数字+点/下划线/连字符)
- DownloadUrl: HTTP/HTTPS URL 格式验证
- FileSha256: 64字符十六进制字符串验证
- FileSize: BigInt类型,2GB上限,支持人类可读格式转换
- Changelog: 更新日志 (10-5000字符)
- MinOsVersion: 最低操作系统版本格式验证

领域层重构:
- AppVersion Entity: 从贫血模型重构为充血模型
  - 私有字段 + getter 封装
  - 业务方法: disable(), enable(), setForceUpdate(), setReleaseDate()
  - 工厂方法: create() (新建), reconstitute() (重建)
  - 使用值对象替代所有原始类型

基础设施层:
- AppVersionMapper: 领域对象与持久化模型转换
- AppVersionRepositoryImpl: 使用 Mapper 进行数据转换
- 更新方法签名使用值对象类型

应用层:
- CreateVersionHandler: 创建值对象后构建领域实体
- CheckUpdateHandler: 从值对象提取值用于响应

共享层:
- DomainException: 领域异常基类

架构改进:
- 完整的 DDD 分层架构
- 值对象封装验证逻辑和业务规则
- 领域实体包含业务行为
- 清晰的领域-持久化边界

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-02 17:33:32 -08:00
Developer c45ed8a575 feat(admin-service): 实现移动应用版本管理服务
- DDD+Hexagonal架构
- Domain层: AppVersion实体, Platform枚举, Repository接口
- Infrastructure层: Prisma集成, Repository实现
- Application层: CheckUpdate查询(供移动端), CreateVersion命令(管理员)
- API层: VersionController, DTOs (request/response)
- 数据库: app_versions表设计(支持Android/iOS)
- 功能: 版本检查、强制更新、文件SHA-256校验
- 部署: Dockerfile, docker-compose.yml, deploy.sh脚本
- 数据库迁移: Prisma migration初始化

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-02 11:22:30 -08:00