From 8d5fb4ee9d27fd6a61b210eaee74af265f76aa7c Mon Sep 17 00:00:00 2001
From: manailin <261030956@qq.com>
Date: 星期五, 08 四月 2022 14:55:18 +0800
Subject: [PATCH] [修改]修改配置

---
 springcloud_k8s_panzhihuazhihuishequ/service_property/src/main/java/com/panzhihua/service_property/netty/NettyServerHandler.java |   21 ++++++++-------------
 1 files changed, 8 insertions(+), 13 deletions(-)

diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_property/src/main/java/com/panzhihua/service_property/netty/NettyServerHandler.java b/springcloud_k8s_panzhihuazhihuishequ/service_property/src/main/java/com/panzhihua/service_property/netty/NettyServerHandler.java
index 4030931..d9f7b8f 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_property/src/main/java/com/panzhihua/service_property/netty/NettyServerHandler.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_property/src/main/java/com/panzhihua/service_property/netty/NettyServerHandler.java
@@ -59,26 +59,21 @@
         if (msg.toString().startsWith("4A1802")) {
             myTools.writeToClient("404A021823", ctx, "状态包");
         }
-        if (msg.toString().startsWith("4A0C0134")) {
+        if (msg.toString().startsWith("4A0C01")) {
             myTools.writeToClient("404A01" + DateUtils.getDateFormatString(new Date(), "HHmmss") + "23", ctx, "心跳包");
         }
         if (msg.toString().startsWith("4A1803")) {
             String serial = msg.toString().substring(14, 24);
             myTools.writeToClient("404A03" + msg.toString().substring(msg.toString().length() - 2) + "23", ctx, "事件包");
-//            ComPropertyAlarm comPropertyAlarm=new ComPropertyAlarm();
-//            comPropertyAlarm.setCreateTime(DateUtil.date());
-//            comPropertyAlarm.setSerialNo(serial);
-//            comPropertyAlarm.setType(ComPropertyAlarm.type.one);
-//            nettyServerHandler.comPropertyAlarmDao.insert(comPropertyAlarm);
             if (msg.toString().startsWith("4A18031")) {
                 //正式处理
-                // delayAlarm(serial);
+                 delayAlarm(serial);
                 //展会处理
-                ComPropertyAlarm comPropertyAlarm = new ComPropertyAlarm();
-                comPropertyAlarm.setCreateTime(DateUtil.date());
-                comPropertyAlarm.setSerialNo(serial);
-                comPropertyAlarm.setType(ComPropertyAlarm.type.one);
-                nettyServerHandler.comPropertyAlarmDao.insert(comPropertyAlarm);
+//                ComPropertyAlarm comPropertyAlarm = new ComPropertyAlarm();
+//                comPropertyAlarm.setCreateTime(DateUtil.date());
+//                comPropertyAlarm.setSerialNo(serial);
+//                comPropertyAlarm.setType(ComPropertyAlarm.type.one);
+//                nettyServerHandler.comPropertyAlarmDao.insert(comPropertyAlarm);
             }
 
         }
@@ -118,7 +113,7 @@
                 nettyServerHandler.stringRedisTemplate.boundValueOps(serial).set(JSONObject.toJSONString(comPropertyEquipment));
             }
             int finalDuration = duration;
-            nettyServerHandler.rabbitTemplate.convertAndSend("delayed.exchange", "delayed.key", comPropertyEquipment, message -> {
+            nettyServerHandler.rabbitTemplate.convertAndSend("huacheng.delayed.exchange", "huacheng.delayed.key", comPropertyEquipment, message -> {
                 message.getMessageProperties().setHeader("x-delay", finalDuration * 1000 * 3601);
                 return message;
             });

--
Gitblit v1.7.1