fix: 修复流量轮询 cache 未同步 last_gateway_reading_mb 导致假增量触发停机死循环
Some checks failed
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Has been cancelled
Some checks failed
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Has been cancelled
This commit is contained in:
@@ -266,7 +266,8 @@ func (h *PollingHandler) HandleCarddataCheck(ctx context.Context, t *asynq.Task)
|
||||
|
||||
// 更新 Redis 缓存
|
||||
h.updateCardCache(ctx, uint(cardID), map[string]any{
|
||||
"current_month_usage_mb": updates["current_month_usage_mb"],
|
||||
"current_month_usage_mb": updates["current_month_usage_mb"],
|
||||
"last_gateway_reading_mb": gatewayFlowMB,
|
||||
})
|
||||
|
||||
// 任务 18.3: 调用 UsageService.DeductDataUsage 进行流量扣减
|
||||
|
||||
Reference in New Issue
Block a user