From 444aaced36d4d3e9c32815b436dcfaff3226094d Mon Sep 17 00:00:00 2001 From: Junjie <540245094@qq.com> Date: 星期三, 13 八月 2025 14:53:57 +0800 Subject: [PATCH] # --- src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java | 10 ++++++++-- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java index 3eee41e..a61bcc8 100644 --- a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java +++ b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java @@ -742,6 +742,12 @@ // continue; // } + //鍫嗗灈鏈哄洖鍘熺偣浠诲姟涓� + Object object = redisUtil.get(RedisConstantType.CRN_MOVE_LOCK); + if (object != null) { + continue; + } + // 鍙湁褰撳爢鍨涙満绌洪棽 骞朵笖 鏃犱换鍔℃椂鎵嶇户缁墽琛� if (crnProtocol.getStatusType() == CrnStatusType.IDLE && crnProtocol.getTaskNo() == 0 && crnProtocol.getModeType() == CrnModeType.AUTO && crnProtocol.getLoaded() == 0 && crnProtocol.getForkPos() == 0) { @@ -841,7 +847,7 @@ News.error("鍫嗗灈鏈虹Щ鍔ㄥ懡浠や笅鍙戝け璐ワ紝鍫嗗灈鏈哄彿={}锛屼换鍔℃暟鎹�={}", crnProtocol.getCrnNo(), JSON.toJSON(crnCommand)); } crnThread.setBackHpFlag(true); - redisUtil.set(RedisConstantType.CRN_MOVE_LOCK + crn.getId(), "lock", 60); + redisUtil.set(RedisConstantType.CRN_MOVE_LOCK + crn.getId(), "lock", 10); try { Thread.sleep(500); } catch (Exception e) { @@ -913,7 +919,7 @@ News.error("鍫嗗灈鏈虹Щ鍔ㄥ懡浠や笅鍙戝け璐ワ紝鍫嗗灈鏈哄彿={}锛屼换鍔℃暟鎹�={}", crnProtocol.getCrnNo(), JSON.toJSON(crnCommand)); } crnThread.setBackHpFlag(true); - redisUtil.set(RedisConstantType.CRN_MOVE_LOCK + crn.getId(), "lock", 60); + redisUtil.set(RedisConstantType.CRN_MOVE_LOCK + crn.getId(), "lock", 10); try { Thread.sleep(500); } catch (Exception e) { -- Gitblit v1.9.1