rwadurian/backend/services/reporting-service/src/infrastructure
hailin 875f86c263 fix(reporting): 修复 contract.signed 事件 BigInt(undefined) 错误
根因:planting-service 发送的 contract.signed 消息为嵌套结构
  { eventName: 'contract.signed', data: { orderNo, userId, ... } }
但 reporting-service handleContractSigned 按扁平结构解析
  message.userId → undefined → BigInt(undefined) → TypeError
导致 ~200 次/10分钟持续报错。

修复:
- 消息类型改为匹配实际嵌套格式 { eventName, data: { ... } }
- 解构 message.data 后再访问各字段
- 添加 userId 防御性检查,避免再次 BigInt 崩溃
- 与 referral-service ContractSigningHandler 消息结构保持一致

影响范围:仅 reporting-service 活动记录,不影响核心业务流程
(referral-service / reward-service 已正确处理嵌套格式)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 07:59:16 -08:00
..
export refactor(mpc-system): migrate to party-driven architecture with PartyID-based routing 2025-12-05 08:11:28 -08:00
external feat(admin-web): 省团队收益汇总明细增加来源用户列并修复账户名称显示 2026-02-05 17:35:22 -08:00
kafka fix(reporting): 修复 contract.signed 事件 BigInt(undefined) 错误 2026-02-15 07:59:16 -08:00
persistence fix(reporting-service): 添加活动记录幂等性处理 2026-01-08 05:46:43 -08:00
redis feat(dashboard): 添加热钱包余额实时显示(公共账户/因子) 2026-01-06 23:04:21 -08:00
infrastructure.module.ts feat(reporting): add system account report aggregation feature 2026-01-04 22:06:58 -08:00