From e424afe3403c5b50672f7ca5551ac8fd4455d162 Mon Sep 17 00:00:00 2001 From: zhenghaoyu Date: Mon, 6 Jan 2025 09:55:21 +0800 Subject: [PATCH 1/4] =?UTF-8?q?1.=E6=89=93=E6=89=98=E6=96=B9=E5=BC=8F?= =?UTF-8?q?=E4=BF=9D=E5=AD=98=E9=80=BB=E8=BE=91=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../warehouse/service/impl/WarehouseTrayTypeServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java index 146c767eb..fad0378fa 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java @@ -1782,7 +1782,7 @@ public class WarehouseTrayTypeServiceImpl extends BaseServiceImpl keys = Collections.singletonList(key); List args = Arrays.asList(value, String.valueOf(expireTime)); - Long result = redis.getRedisTemplate().execute(redisScript, keys, args); + Long result = redis.getStringRedisTemplate().execute(redisScript, keys, args); if (result == 1) { log.warn("#########orderScanOrderPackageCode: 托盘正在保存打托方式 trayCode={} warehouseId={}", trayCode, warehouseId); From 5b5b23070842038f827aaf80279f7d4c4f378048 Mon Sep 17 00:00:00 2001 From: "pref_mail@163.com" Date: Mon, 6 Jan 2025 11:02:32 +0800 Subject: [PATCH 2/4] =?UTF-8?q?fix=EF=BC=9A=E4=BF=AE=E5=A4=8D=E7=AD=BE?= =?UTF-8?q?=E6=94=B6=E6=97=A5=E5=BF=97=E6=B2=A1=E7=94=A8=E7=AD=BE=E6=94=B6?= =?UTF-8?q?=E4=BA=BA=E5=90=8D=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/DistributionSignforServiceImpl.java | 2 +- .../factory/receiver/OrderStatusHandler.java | 146 ------------------ 2 files changed, 1 insertion(+), 147 deletions(-) diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java index 36e335493..9d8426064 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java @@ -8140,7 +8140,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl m = new HashMap<>(); -// m.put("trayType",newTrayType); -// m.put("trayCode","T"+trayId); -// m.put("warehouseId",warehouseId); -// m.put("orderPackageCode",unitNo); -// -// R response = warehouseTrayTypeClient.orderScanOrderPackageCodeReturnR(m); -// int code = response.getCode(); -// if(code == 4001){ -// log.info("####################orderStatusHandler: 包件已在当前托盘打托 unitNo={} trayCode={}",unitNo,"T"+trayId); -// }else if(code == 4002){ -// log.info("####################orderStatusHandler: 包件已在其他托盘打托 unitNo={} ",unitNo); -// WarehouseTrayGoodsEntity trayGoodsEntity = warehouseTrayGoodsClient.findTrayCodeByOrderPackageCode(unitNo); -// if(Objects.isNull(trayGoodsEntity)){ -// log.warn("####################orderStatusHandler: 包件未打托 unitNo={}",unitNo); -// }else{ -// String oldTrayCode = trayGoodsEntity.getTrayCode(); -// Long trayGoodsId = trayGoodsEntity.getId(); -// Long wid = trayGoodsEntity.getWarehouseId(); -// BasicdataTrayEntity oldTrayEntity = basicdataTrayClient.getTrayByTrayCode(oldTrayCode); -// Long oldTrayId = oldTrayEntity.getId(); -// //判断托盘是否有上架 -// Long oldAllocationId = taryAllocationClient.findAllocationByTrayId(oldTrayId); -// if (Objects.isNull(oldAllocationId)){ -// //没有上架 -// //直接解绑托盘 -// warehouseTrayGoodsClient.delTrayGoodsById(trayGoodsId,wid); -// }else{ -// //有上架 -// //下架 -// updownTypeClient.downPackage(unitNo,wid); -// } -// } -// -// boolean b1 = warehouseTrayTypeClient.orderScanOrderPackageCode(m); -// if(!b1){ -// log.warn("####################orderStatusHandler: 二次打托失败 unitNo={} trayCode={}",unitNo,"T"+trayId); -// }else{ -// log.info("####################orderStatusHandler: 二次打托成功 unitNo={} trayCode={}",unitNo,"T"+trayId); -// } -// }else if(code == 4003){ -// log.info("####################orderStatusHandler: 包件未打托已上架 unitNo={} ",unitNo); -// WarehouseUpdownGoodsEntity updownGoodsEntity = warehouseUpdownGoodsClient.findEntityByOrderPackageCode(unitNo); -// if(Objects.isNull(updownGoodsEntity)){ -// log.warn("####################orderStatusHandler: 包件未上架 unitNo={}",unitNo); -// }else{ -// Long wid = updownGoodsEntity.getWarehouseId(); -// updownTypeClient.downPackage(unitNo,wid); -// } -// boolean b1 = warehouseTrayTypeClient.orderScanOrderPackageCode(m); -// if(!b1){ -// log.warn("####################orderStatusHandler: 二次打托失败 unitNo={} trayCode={}",unitNo,"T"+trayId); -// }else{ -// log.info("####################orderStatusHandler: 二次打托成功 unitNo={} trayCode={}",unitNo,"T"+trayId); -// } -// }else if(code == 4004){ -// log.info("####################orderStatusHandler: 包件打托方式不正确 unitNo={} ",unitNo); -// //先去空置托盘再打托 -// warehouseTrayTypeClient.trayToNull("T"+trayId); -// boolean b1 = warehouseTrayTypeClient.orderScanOrderPackageCode(m); -// if(!b1){ -// log.warn("####################orderStatusHandler: 二次打托失败 unitNo={} trayCode={}",unitNo,"T"+trayId); -// } -// }else{ -// String msg1 = r.getMsg(); -// int code1 = r.getCode(); -// log.warn("######################orderStatusHandler: 打托失败 msg={} code={}",msg1,code1); -// log.warn("######################orderStatusHandler: 打托失败 unitNo={} trayCode={}",unitNo,"T"+trayId); -// } -// -// }else{ -// //有上架就上架 -// updownTypeClient.upShelfPackage(unitNo,allocationId,warehouseId); -// } -// } - } } From 97dc37323f9da7b70768c12302cb4927eb9fef92 Mon Sep 17 00:00:00 2001 From: zhenghaoyu Date: Mon, 6 Jan 2025 12:57:06 +0800 Subject: [PATCH 3/4] =?UTF-8?q?1.=E6=89=93=E6=89=98=E6=96=B9=E5=BC=8F?= =?UTF-8?q?=E4=BF=9D=E5=AD=98=E9=80=BB=E8=BE=91=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/WarehouseTrayTypeServiceImpl.java | 11 +++++++---- .../src/main/resources/luascript/resubmit.lua | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java index fad0378fa..95a996a8f 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java @@ -1780,16 +1780,19 @@ public class WarehouseTrayTypeServiceImpl extends BaseServiceImpl keys = Collections.singletonList(key); - List args = Arrays.asList(value, String.valueOf(expireTime)); + List args = Arrays.asList(value, expireTime); - Long result = redis.getStringRedisTemplate().execute(redisScript, keys, args); + log.info("Keys: {}", keys); + log.info("Args: {}", args); + + Long result = redis.getRedisTemplate().execute(redisScript, keys, args.toArray()); if (result == 1) { log.warn("#########orderScanOrderPackageCode: 托盘正在保存打托方式 trayCode={} warehouseId={}", trayCode, warehouseId); throw new CustomerException(405, "托盘信息正在更新,请重试"); } - redis.setEx(key,"1",5L); +// redis.setEx(key,"1",5L); WarehouseTrayTypeEntity trayTypeEntity = new WarehouseTrayTypeEntity(); BladeUser user = AuthUtil.getUser(); @@ -1879,7 +1882,7 @@ public class WarehouseTrayTypeServiceImpl extends BaseServiceImpl Date: Mon, 6 Jan 2025 15:48:31 +0800 Subject: [PATCH 4/4] =?UTF-8?q?fix:=E4=BF=AE=E6=94=B9=E5=9C=B0=E5=B1=82?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=8A=A0=E8=BD=BD=E9=A1=BA=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/application-dev.yml | 3 +++ .../src/main/resources/application-dev.yml | 20 +++++++++++++++++-- .../src/main/resources/application-prod.yml | 10 +++++++--- .../src/main/resources/application-test.yml | 7 +++++++ 4 files changed, 35 insertions(+), 5 deletions(-) diff --git a/blade-service/logpm-distribution/src/main/resources/application-dev.yml b/blade-service/logpm-distribution/src/main/resources/application-dev.yml index 2ced6d350..886f4678d 100644 --- a/blade-service/logpm-distribution/src/main/resources/application-dev.yml +++ b/blade-service/logpm-distribution/src/main/resources/application-dev.yml @@ -45,6 +45,9 @@ spring: datasource: dynamic: druid: +# connect-timeout: 60000 + + #通用校验配置 validation-query: select 1 #启用sql日志拦截器 diff --git a/blade-service/logpm-report/src/main/resources/application-dev.yml b/blade-service/logpm-report/src/main/resources/application-dev.yml index e75326109..fb8d122aa 100644 --- a/blade-service/logpm-report/src/main/resources/application-dev.yml +++ b/blade-service/logpm-report/src/main/resources/application-dev.yml @@ -21,16 +21,32 @@ spring: #启用sql日志拦截器 proxy-filters: - sqlLogInterceptor - query-timeout: 60000 - #设置默认的数据源或者数据源组,默认值即为master +# query-timeout: 60000 +# connect-timeout: 60000 +# transaction-timeout: 60000 +# max-wait: 60000 +# time-between-eviction-runs-millis: 60000 +# min-evictable-idle-time-millis: 300000 +# connectTimeout: 60000 +# socketTimeout: 60000 +# queryTimeout: 60000 + #设置默认的数据源或者数据源组,默认值即为master primary: master datasource: master: druid: #独立校验配置 validation-query: select 1 + queryTimeout: 60000 #oracle校验 #validation-query: select 1 from dual url: ${blade.datasource.report.master.url} username: ${blade.datasource.report.master.username} password: ${blade.datasource.report.master.password} + 627683: + druid: + validation-query: select 1 + queryTimeout: 60000 + url: jdbc:mysql://192.168.2.46:3306/logpm_platform?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&transformedBitIsBoolean=true&tinyInt1isBit=false&allowMultiQueries=true&serverTimezone=GMT%2B8&allowPublicKeyRetrieval=true&socketTimeout=30000 + username: root + password: 12345678 diff --git a/blade-service/logpm-report/src/main/resources/application-prod.yml b/blade-service/logpm-report/src/main/resources/application-prod.yml index d2d395e11..09f492296 100644 --- a/blade-service/logpm-report/src/main/resources/application-prod.yml +++ b/blade-service/logpm-report/src/main/resources/application-prod.yml @@ -21,9 +21,6 @@ spring: #启用sql日志拦截器 proxy-filters: - sqlLogInterceptor - query-timeout: 60000 - time-between-eviction-runs-millis: 60000 - min-evictable-idle-time-millis: 300000 #设置默认的数据源或者数据源组,默认值即为master primary: master datasource: @@ -36,3 +33,10 @@ spring: url: ${blade.datasource.report.master.url} username: ${blade.datasource.report.master.username} password: ${blade.datasource.report.master.password} + 627683: + druid: + validation-query: select 1 + queryTimeout: 60000 + url: ${blade.datasource.report.627683.url} + username: ${blade.datasource.report.627683.username} + password: ${blade.datasource.report.627683.password} diff --git a/blade-service/logpm-report/src/main/resources/application-test.yml b/blade-service/logpm-report/src/main/resources/application-test.yml index e75326109..9f962556a 100644 --- a/blade-service/logpm-report/src/main/resources/application-test.yml +++ b/blade-service/logpm-report/src/main/resources/application-test.yml @@ -34,3 +34,10 @@ spring: url: ${blade.datasource.report.master.url} username: ${blade.datasource.report.master.username} password: ${blade.datasource.report.master.password} + 627683: + druid: + validation-query: select 1 + queryTimeout: 60000 + url: ${blade.datasource.report.627683.url} + username: ${blade.datasource.report.627683.username} + password: ${blade.datasource.report.627683.password}