From 3b58972c757734f0dc4b1ff29a0a179ed564ab64 Mon Sep 17 00:00:00 2001
From: Administrator <zhubaomin>
Date: 星期三, 17 七月 2024 11:47:42 +0800
Subject: [PATCH] 2024-07-17 朱宝民 重构命令日志表,返回结果改为text类型

---
 pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/Server.java |   12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)

diff --git a/pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/Server.java b/pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/Server.java
index 4a7d391..01ef2c9 100644
--- a/pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/Server.java
+++ b/pipIrr-platform/pipIrr-mw/pipIrr-mw-rtu/src/main/java/com/dy/rtuMw/Server.java
@@ -130,6 +130,10 @@
 		try {
 			///////////////
 			//鍩烘湰閰嶇疆
+			ServerProperties.orgTag = this.conf.getSetAttrTxt(this.doc, "config.base", "orgTag", null, false, null) ;
+			if(ServerProperties.orgTag==null || ServerProperties.orgTag.trim().equals("")){
+				throw new Exception("鏈烘瀯tag涓嶈兘涓虹┖") ;
+			}
 			ServerProperties.isLowPower = conf.getSetAttrBoolean(doc, "config.base", "isLowPower", null, null) ; 
 			if(ServerProperties.isLowPower == null){
 				ServerProperties.isLowPower = false ;
@@ -151,7 +155,7 @@
 			//涓嶅湪绾跨紦瀛樼殑鍛戒护鏈�澶х紦瀛樻椂闀�
 			ServerProperties.offLineCachTimeout = conf.getSetAttrPlusInt(doc, "config.base", "offLineCachTimeout", null, 15, 172800, null) * 1000L ;
 			//TCP涓婅鏁版嵁鏃跺埢缂撳瓨鏃堕暱锛屽綋杈惧埌鏃堕暱鏃讹紝TCP涓婅鏁版嵁鏃跺埢琚竻绌猴紝閲囩敤TCP涓婅鏁版嵁鏃跺埢鐩殑鏄紝闃绘涓婃暟鎹悓鏃朵笅鍙戞暟鎹紝鍥犱负RTU澶勭悊涓嶈繃鏉�
-			ServerProperties.lastUpDataTimeLive = conf.getSetAttrPlusInt(doc, "config.base", "lastUpDataTimeLive", null, 0, 5, null) * 1000L ;
+			ServerProperties.lastUpDataTimeLive = conf.getSetAttrPlusInt(doc, "config.base", "lastUpDataTimeLive", null, 0, 5000, null) * 1L ;
 			//鏁版嵁搴撴暟鎹甶d鐢熸垚鍣ㄧ殑id鍚庣紑锛�0鏄粯璁ょ殑鍚庣紑锛屼竴鑸瑆eb绯荤粺搴旂敤锛屾暟鎹腑闂翠欢id鍚庣紑澶т簬绛変簬1
 			ServerProperties.dbDataIdSuffix = conf.getSetAttrInt(doc, "config.base", "dbDataIdSuffix", null, 0, 99, null);
 			//涓婁笅琛屾暟鎹紦瀛橀槦鍒椾腑缂撳瓨鏁版嵁涓暟鐨勬姤璀﹂噺锛岃繖涓笌鐜板疄椤圭洰鎵�鎺ユ按琛ㄦ暟鐩稿叧
@@ -161,6 +165,12 @@
 			if(ServerProperties.cacheUpDownDataMaxCount <= ServerProperties.cacheUpDownDataWarnCount){
 				throw new Exception("cacheUpDownDataMaxCount蹇呴』澶т簬cacheUpDownDataWarnCount") ;
 			}
+			//娌℃湁涓婅鏁版嵁鐨勫垎閽熸暟锛岃揪鍒拌繖涓垎閽熸暟锛岃涓篟TU鏂綉浜嗭紝鍙栧�艰寖鍥存槸2_100
+			ServerProperties.disconnectedByNoUpDataMinutes =  0L + conf.getSetAttrPlusInt(doc, "config.base", "disconnectedByNoUpDataMinutes", null, 1, 100, null) ;
+			if(ServerProperties.disconnectedByNoUpDataMinutes < 1 || ServerProperties.disconnectedByNoUpDataMinutes > 100){
+				throw new Exception("disconnectedByNoUpDataMinutes鍙栧�煎繀椤绘槸1~100") ;
+			}
+			ServerProperties.disconnectedByNoUpDataMinutes = ServerProperties.disconnectedByNoUpDataMinutes * 60 * 1000 ;
 
 			//璁剧疆ID鐢熸垚鍣ㄧ殑鍚庣紑
 			IDLongGenerator.setSuffix(ServerProperties.dbDataIdSuffix.intValue());

--
Gitblit v1.8.0