Go to file
zerosaturation 3d3f2260f3 feat(statistic): T13-T16 Gateway routes + 5-service business integration (7/7 event types)
Gateway:
- 7 routes /api/v1/dashboard/* with JWT auth (middleware.AuthMiddleware)
- statistic_controller.go: 7 methods, response format {code:200, data:resp}
- gateway/main.go: StatisticServiceClient wired
- gateway/config: StatisticServiceURL (DUBBO_STATISTIC_SERVICE_URL, default tri://127.0.0.1:20009)

pkg/statistic SDK:
- fire-and-forget TrackEvent + BatchTrackEvent
- Init(client) + Get() global singleton pattern

Business-side integration (7/7 event types):
- socialService.LikeAsset → asset.like
- galleryService.PlaceAsset → exhibition.start
- galleryService.RemoveFromSlot → exhibition.end (with duration_ms)
- taskService.OnExhibitionCompleted → exhibition.revenue
- assetService.CreateMintOrder → asset.mint
- assetService.logLevelChange → asset.level_up
- userService.UpdateCrystalBalance → crystal.change (wrapper fn added)

Cache warmup:
- main.go: 7 RPCs x 5 sample starIDs at startup (15s delay)
- prevents cold-start DB thundering herd

Existing service modifications:
- galleryService/exhibition_service.go
- taskService/revenue_service.go
- assetService/{mint_service,asset_level_service}.go
- userService/user_service.go
- socialService/asset_like_service.go

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

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-08 17:20:53 +08:00
.agents/skills feat:实现AI生成镭射卡功能 2026-06-03 22:19:22 +08:00
backend feat(statistic): T13-T16 Gateway routes + 5-service business integration (7/7 event types) 2026-06-08 17:20:53 +08:00
docker feat: 修改头像显示不全,修改docker的配置 2026-06-04 16:41:20 +08:00
docs docs(statistic): add 本期实施范围 chapter to design doc + implementation plan 2026-06-08 17:20:53 +08:00
frontend feat:增加env配置 2026-06-05 12:26:05 +08:00
mock feat: 修改遗留bug 2026-04-12 16:05:13 +08:00
scripts 压缩图片 2026-05-06 12:04:34 +08:00
supabase/migrations feat: 合并代码,解决冲突 2026-05-16 02:42:32 +08:00
.gitignore feat(statistic): scaffold statisticService with go.mod and directory structure 2026-06-08 17:20:53 +08:00
AGENTS.md feat:实现AI生成镭射卡功能 2026-06-03 22:19:22 +08:00
CLAUDE.md fix: 样式修复、创作者头像修复 2026-06-03 18:13:16 +08:00
README.md fix:修改瀑布流ios的抖动现象 2026-05-13 13:03:45 +08:00

TopFans