From e404cd26d4c2e0a6b0a27a8f78f61c88bfdc5f11 Mon Sep 17 00:00:00 2001
From: "zhuangpeng.li" <908349383@qq.com>
Date: Wed, 16 Apr 2025 14:31:24 +0800
Subject: [PATCH] =?UTF-8?q?build(=E4=BE=9D=E8=B5=96=E5=8C=85=E6=95=B4?=
=?UTF-8?q?=E7=90=86):=20=E4=BE=9D=E8=B5=96=E5=8C=85=E7=89=88=E6=9C=AC?=
=?UTF-8?q?=E7=BB=9F=E4=B8=80=E6=95=B4=E7=90=86?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
springboot/fastbee-admin/pom.xml | 2 +-
springboot/fastbee-common/pom.xml | 13 +---
.../com/fastbee/common/utils/DateUtils.java | 20 +++---
.../fastbee/framework/web/domain/Server.java | 21 +++---
.../framework/web/domain/server/Cpu.java | 3 +-
.../framework/web/domain/server/Jvm.java | 8 ++-
.../framework/web/domain/server/Mem.java | 3 +-
.../framework/web/domain/server/Sys.java | 2 +-
.../framework/web/domain/server/SysFile.java | 2 +-
springboot/fastbee-gateway/fastbee-mq/pom.xml | 1 +
.../fastbee-gateway/gateway-boot/pom.xml | 1 +
.../fastbee-plugs/fastbee-ruleEngine/pom.xml | 1 -
.../fastbee-iot-service/pom.xml | 10 +--
springboot/pom.xml | 64 +++++++++++++------
14 files changed, 85 insertions(+), 66 deletions(-)
diff --git a/springboot/fastbee-admin/pom.xml b/springboot/fastbee-admin/pom.xml
index 6c56202c..66c386a4 100644
--- a/springboot/fastbee-admin/pom.xml
+++ b/springboot/fastbee-admin/pom.xml
@@ -34,7 +34,7 @@
io.swagger
swagger-models
- 1.6.2
+ ${io.swagger.version}
diff --git a/springboot/fastbee-common/pom.xml b/springboot/fastbee-common/pom.xml
index e5eba079..b769c977 100644
--- a/springboot/fastbee-common/pom.xml
+++ b/springboot/fastbee-common/pom.xml
@@ -40,6 +40,7 @@
com.baomidou
mybatis-plus-boot-starter
+
com.baomidou
mybatis-plus-generator
@@ -74,7 +75,6 @@
com.baomidou
dynamic-datasource-spring-boot-starter
- 3.5.2
@@ -150,20 +150,11 @@
io.swagger
swagger-annotations
- 1.6.2
- compile
+
org.eclipse.paho
org.eclipse.paho.client.mqttv3
- 1.2.5
- compile
-
-
- org.eclipse.paho
- org.eclipse.paho.client.mqttv3
- 1.2.5
- compile
diff --git a/springboot/fastbee-common/src/main/java/com/fastbee/common/utils/DateUtils.java b/springboot/fastbee-common/src/main/java/com/fastbee/common/utils/DateUtils.java
index 1da888b3..cb132ad7 100644
--- a/springboot/fastbee-common/src/main/java/com/fastbee/common/utils/DateUtils.java
+++ b/springboot/fastbee-common/src/main/java/com/fastbee/common/utils/DateUtils.java
@@ -1,18 +1,14 @@
package com.fastbee.common.utils;
+import org.apache.commons.lang3.time.DateFormatUtils;
+
import java.lang.management.ManagementFactory;
import java.text.ParseException;
import java.text.SimpleDateFormat;
-import java.time.LocalDate;
-import java.time.LocalDateTime;
-import java.time.LocalTime;
-import java.time.ZoneId;
-import java.time.ZonedDateTime;
+import java.time.*;
import java.util.Date;
import java.util.Random;
-import org.apache.commons.lang3.time.DateFormatUtils;
-
/**
* 时间工具类
*
@@ -160,16 +156,20 @@ public class DateUtils extends org.apache.commons.lang3.time.DateUtils
}
/**
- * 计算两个时间差
+ * 计算时间差
+ *
+ * @param endDate 最后时间
+ * @param startTime 开始时间
+ * @return 时间差(天/小时/分钟)
*/
- public static String getDatePoor(Date endDate, Date nowDate)
+ public static String timeDistance(Date endDate, Date startTime)
{
long nd = 1000 * 24 * 60 * 60;
long nh = 1000 * 60 * 60;
long nm = 1000 * 60;
// long ns = 1000;
// 获得两个时间的毫秒时间差异
- long diff = endDate.getTime() - nowDate.getTime();
+ long diff = endDate.getTime() - startTime.getTime();
// 计算差多少天
long day = diff / nd;
// 计算差多少小时
diff --git a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/Server.java b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/Server.java
index b9173e00..28ba3af1 100644
--- a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/Server.java
+++ b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/Server.java
@@ -1,16 +1,8 @@
package com.fastbee.framework.web.domain;
-import java.net.UnknownHostException;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.Properties;
import com.fastbee.common.utils.Arith;
import com.fastbee.common.utils.ip.IpUtils;
-import com.fastbee.framework.web.domain.server.Cpu;
-import com.fastbee.framework.web.domain.server.Jvm;
-import com.fastbee.framework.web.domain.server.Mem;
-import com.fastbee.framework.web.domain.server.Sys;
-import com.fastbee.framework.web.domain.server.SysFile;
+import com.fastbee.framework.web.domain.server.*;
import oshi.SystemInfo;
import oshi.hardware.CentralProcessor;
import oshi.hardware.CentralProcessor.TickType;
@@ -21,15 +13,20 @@ import oshi.software.os.OSFileStore;
import oshi.software.os.OperatingSystem;
import oshi.util.Util;
+import java.net.UnknownHostException;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Properties;
+
/**
* 服务器相关信息
- *
+ *
* @author ruoyi
*/
public class Server
{
private static final int OSHI_WAIT_SECOND = 1000;
-
+
/**
* CPU相关信息
*/
@@ -209,7 +206,7 @@ public class Server
/**
* 字节转换
- *
+ *
* @param size 字节大小
* @return 转换后值
*/
diff --git a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Cpu.java b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Cpu.java
index 705b2825..e02e11a6 100644
--- a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Cpu.java
+++ b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Cpu.java
@@ -1,10 +1,11 @@
package com.fastbee.framework.web.domain.server;
+
import com.fastbee.common.utils.Arith;
/**
* CPU相关信息
- *
+ *
* @author ruoyi
*/
public class Cpu
diff --git a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Jvm.java b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Jvm.java
index 5d45a7b5..8ea3296a 100644
--- a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Jvm.java
+++ b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Jvm.java
@@ -1,12 +1,14 @@
package com.fastbee.framework.web.domain.server;
-import java.lang.management.ManagementFactory;
+
import com.fastbee.common.utils.Arith;
import com.fastbee.common.utils.DateUtils;
+import java.lang.management.ManagementFactory;
+
/**
* JVM相关信息
- *
+ *
* @author ruoyi
*/
public class Jvm
@@ -117,7 +119,7 @@ public class Jvm
*/
public String getRunTime()
{
- return DateUtils.getDatePoor(DateUtils.getNowDate(), DateUtils.getServerStartDate());
+ return DateUtils.timeDistance(DateUtils.getNowDate(), DateUtils.getServerStartDate());
}
/**
diff --git a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Mem.java b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Mem.java
index 44074dfa..ccded294 100644
--- a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Mem.java
+++ b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Mem.java
@@ -1,10 +1,11 @@
package com.fastbee.framework.web.domain.server;
+
import com.fastbee.common.utils.Arith;
/**
* 內存相关信息
- *
+ *
* @author ruoyi
*/
public class Mem
diff --git a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Sys.java b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Sys.java
index c7b2f257..e643684e 100644
--- a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Sys.java
+++ b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/Sys.java
@@ -2,7 +2,7 @@ package com.fastbee.framework.web.domain.server;
/**
* 系统相关信息
- *
+ *
* @author ruoyi
*/
public class Sys
diff --git a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/SysFile.java b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/SysFile.java
index 80edd964..5c7e4f0f 100644
--- a/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/SysFile.java
+++ b/springboot/fastbee-framework/src/main/java/com/fastbee/framework/web/domain/server/SysFile.java
@@ -2,7 +2,7 @@ package com.fastbee.framework.web.domain.server;
/**
* 系统文件相关信息
- *
+ *
* @author ruoyi
*/
public class SysFile
diff --git a/springboot/fastbee-gateway/fastbee-mq/pom.xml b/springboot/fastbee-gateway/fastbee-mq/pom.xml
index b8c62e46..bdf7b19d 100644
--- a/springboot/fastbee-gateway/fastbee-mq/pom.xml
+++ b/springboot/fastbee-gateway/fastbee-mq/pom.xml
@@ -20,6 +20,7 @@
cn.hutool
hutool-all
+
com.fastbee
fastbee-mqtt-client
diff --git a/springboot/fastbee-gateway/gateway-boot/pom.xml b/springboot/fastbee-gateway/gateway-boot/pom.xml
index 83ccb6f4..b0069561 100644
--- a/springboot/fastbee-gateway/gateway-boot/pom.xml
+++ b/springboot/fastbee-gateway/gateway-boot/pom.xml
@@ -17,6 +17,7 @@
com.fastbee
fastbee-mq
+
com.fastbee
fastbee-mqtt-client
diff --git a/springboot/fastbee-plugs/fastbee-ruleEngine/pom.xml b/springboot/fastbee-plugs/fastbee-ruleEngine/pom.xml
index 3eaaff4f..cd77bea2 100644
--- a/springboot/fastbee-plugs/fastbee-ruleEngine/pom.xml
+++ b/springboot/fastbee-plugs/fastbee-ruleEngine/pom.xml
@@ -38,7 +38,6 @@
org.apache.commons
commons-text
- ${commons.text.version}
diff --git a/springboot/fastbee-service/fastbee-iot-service/pom.xml b/springboot/fastbee-service/fastbee-iot-service/pom.xml
index b44ca5d4..1e29cb9a 100644
--- a/springboot/fastbee-service/fastbee-iot-service/pom.xml
+++ b/springboot/fastbee-service/fastbee-iot-service/pom.xml
@@ -23,12 +23,12 @@
com.fastbee
fastbee-common
+
io.swagger
swagger-annotations
- 1.6.2
- compile
+
org.apache.velocity
velocity-engine-core
@@ -41,10 +41,10 @@
com.fastbee
fastbee-quartz
+
org.apache.commons
commons-text
- 1.6
@@ -62,10 +62,10 @@
spring-boot-configuration-processor
true
+
org.eclipse.paho
org.eclipse.paho.client.mqttv3
- 1.2.5
@@ -94,7 +94,7 @@
com.taosdata.jdbc
taos-jdbcdriver
- 2.0.38
+ ${tdengine.version}
diff --git a/springboot/pom.xml b/springboot/pom.xml
index 534796ad..06054532 100644
--- a/springboot/pom.xml
+++ b/springboot/pom.xml
@@ -18,17 +18,16 @@
UTF-8
UTF-8
1.8
+ 2.5.15
+
3.1.1
- 1.2.15
1.21
3.0.0
+ 1.6.2
2.3.3
2.2.0
- 1.4.6
- 2.0.20
- 6.1.6
- 5.9.0
- 2.11.0
+ 6.6.5
+ 5.13.0
1.4
3.2.2
4.1.2
@@ -42,12 +41,25 @@
1.5.5.Final
3.5.3.1
3.5.3.1
+ 4.3.1
+ 2.0.38
32.0.1-jre
-
2.2.3
3.3.1
2.12.2
1.10.0
+ 1.2.5
+
+ 1.2.23
+ 1.4.7
+ 2.0.53
+ 6.6.5
+ 2.13.0
+
+ 9.0.102
+ 1.2.13
+ 5.7.12
+ 5.3.39
@@ -96,6 +108,25 @@
${mybatis-plus-generator.version}
+
+
+ com.baomidou
+ dynamic-datasource-spring-boot-starter
+ ${dynamic-datasource.version}
+
+
+
+ org.eclipse.paho
+ org.eclipse.paho.client.mqttv3
+ ${paho.mqtt.version}
+
+
+
+ io.swagger
+ swagger-annotations
+ ${io.swagger.version}
+
+
com.github.pagehelper
@@ -149,6 +180,12 @@
${commons.fileupload.version}
+
+ org.apache.commons
+ commons-text
+ ${commons.text.version}
+
+
org.apache.poi
@@ -272,12 +309,6 @@
${fastbee.version}
-
- com.fastbee
- fastbee-oss
- ${fastbee.version}
-
-
com.fastbee
@@ -332,12 +363,7 @@
boot-strap
${fastbee.version}
-
-
- com.fastbee
- fastbee-protocol-base
- ${fastbee.version}
-
+
com.fastbee