From 0480422d216701e7c8252f45f89ec129a79a8084 Mon Sep 17 00:00:00 2001 From: YXY <932687738@qq.com> Date: Mon, 20 Mar 2023 23:31:12 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BC=93=E5=AD=98=E8=BF=87=E6=9C=9F=E6=97=B6?= =?UTF-8?q?=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../strategy/callback/MultidimensionalTableCallback.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ruoyi-flyingbook/src/main/java/com/ruoyi/flyingbook/strategy/callback/MultidimensionalTableCallback.java b/ruoyi-flyingbook/src/main/java/com/ruoyi/flyingbook/strategy/callback/MultidimensionalTableCallback.java index 1188ac7..99c2c0a 100644 --- a/ruoyi-flyingbook/src/main/java/com/ruoyi/flyingbook/strategy/callback/MultidimensionalTableCallback.java +++ b/ruoyi-flyingbook/src/main/java/com/ruoyi/flyingbook/strategy/callback/MultidimensionalTableCallback.java @@ -19,6 +19,7 @@ import org.springframework.stereotype.Service; import java.util.ArrayList; import java.util.Date; import java.util.List; +import java.util.concurrent.TimeUnit; /** * @author yuxiangyong @@ -88,13 +89,13 @@ public class MultidimensionalTableCallback extends CallbackAbstract { event = JSONObject.parseObject(eventStr, Event.class); } //如果已经存在处理中的就不需要操作数据库了 - if (event != null && EventOperateStatus.PENDING.getCode().equals(event.getOperateStatus())) { + if (event != null && EventOperateStatus.PENDING.getCode().equals(event.getOperateStatus()) && event.getNumbers() < 3) { continue; } event = this.buildDto(request, event,recordId); if (event.getId() == null) { eventService.insertEvent(event); - redisTemplate.opsForValue().set(cacheKey, JSONObject.toJSONString(event)); + redisTemplate.opsForValue().set(cacheKey, JSONObject.toJSONString(event),1, TimeUnit.MINUTES); } else { updateEventList.add(event.getId()); }