Authored by zhaoqing

清缓存

@@ -45,7 +45,7 @@ public class DrawlineUserQueueRest { @@ -45,7 +45,7 @@ public class DrawlineUserQueueRest {
45 //对当前助力用户进行校验是否是重复助力排队 45 //对当前助力用户进行校验是否是重复助力排队
46 Boolean existFlag = drawlineUserQueueService.judgeHelpUserExist(drawlineUserQueueReqBO); 46 Boolean existFlag = drawlineUserQueueService.judgeHelpUserExist(drawlineUserQueueReqBO);
47 if (existFlag){ 47 if (existFlag){
48 - return new ApiResponse.ApiResponseBuilder().code(9001).message("您已助力,不可重复助力").build(); 48 + return new ApiResponse.ApiResponseBuilder().code(9001).message("您已参加过活动,请刷新重试").build();
49 } 49 }
50 int code = 200; 50 int code = 200;
51 String message = "操作成功"; 51 String message = "操作成功";
@@ -183,6 +183,8 @@ public class DrawlineUserQueueServiceImpl implements IDrawlineUserQueueService { @@ -183,6 +183,8 @@ public class DrawlineUserQueueServiceImpl implements IDrawlineUserQueueService {
183 logger.warn("addDrawlineUserQueue: fail to addDrawlineUserQueue. uid is {}, activityId is {}, userType is {}", uid, activityId, userType); 183 logger.warn("addDrawlineUserQueue: fail to addDrawlineUserQueue. uid is {}, activityId is {}, userType is {}", uid, activityId, userType);
184 throw new ServiceException(900001007, "参加活动排队失败"); 184 throw new ServiceException(900001007, "参加活动排队失败");
185 } 185 }
  186 + String redisKeySuffix = uid + ":" + userType + ":" + activityId;
  187 + redisValueCache.delete(CacheKeyEnum.DRAWLINE_USERACTIVITY, redisKeySuffix);
186 //如果首次参加排队活动成功,则进行消息推送 188 //如果首次参加排队活动成功,则进行消息推送
187 //先判断是否是首次,根据活动ID查询是否只有一条数据 189 //先判断是否是首次,根据活动ID查询是否只有一条数据
188 Integer queueCount = drawlineUserQueueDAO.selectHelpUserCount(activityId, uid, null); 190 Integer queueCount = drawlineUserQueueDAO.selectHelpUserCount(activityId, uid, null);