Browse Source

升级 spring 到最新

zhzhenqin 1 year ago
parent
commit
359feb8dcd

+ 17 - 2
README.md

@@ -52,8 +52,23 @@ URule PRO版在线示例:[http://112.124.15.63:8084/index.html](http://112.124
 
 群号:423339793
 
-#### ![](https://github.com/youseries/assets/blob/master/images/qq-qrcode.png)
-
 # License
 
 Apache-2.0
+
+# 安装
+
+首先 check 代码到本地,进入到 `urule-parent`
+
+```shell
+cd urule-parent
+mvn clean compile install -DskipTests
+```
+
+然后进入到 urule 根目录, 安装所有模块
+
+```shell
+cd ..
+mvn clean compile install -DskipTests
+```
+

+ 10 - 8
urule-console/pom.xml

@@ -7,7 +7,7 @@
   </parent>
   <artifactId>urule-console</artifactId>
   <version>2.1.8-SNAPSHOT</version>
-	
+
   <dependencies>
   	<dependency>
   		<groupId>com.bstek.urule</groupId>
@@ -30,16 +30,18 @@
   		<artifactId>jcr</artifactId>
   		<version>2.0</version>
   	</dependency>
-  		<dependency>
-  		<groupId>javax.servlet</groupId>
-  		<artifactId>servlet-api</artifactId>
-  		<version>2.5</version>
-  		<scope>provided</scope>
-	</dependency>
+  		
+			<dependency>
+				<groupId>jakarta.servlet</groupId>
+				<artifactId>jakarta.servlet-api</artifactId>
+				<version>4.0.4</version>
+				<scope>provided</scope>
+			</dependency>
+
 	  <dependency>
 		  <groupId>org.springframework</groupId>
 		  <artifactId>spring-web</artifactId>
-		  <version>5.2.3.RELEASE</version>
+		  <version>${spring.version}</version>
 	  </dependency>
 	<dependency>
 	    <groupId>commons-fileupload</groupId>

+ 5 - 5
urule-core/pom.xml

@@ -6,11 +6,11 @@
   	<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
   </properties>  
   <dependencies>
-	<dependency>
+  	<dependency>
 	    <groupId>org.antlr</groupId>
 	    <artifactId>antlr4-runtime</artifactId>
 	    <version>4.5</version>
-	</dependency>
+	  </dependency>
 
 	  <!-- lombok插件 -->
 	  <dependency>
@@ -43,19 +43,19 @@
 	<dependency>
   		<groupId>org.springframework</groupId>
   		<artifactId>spring-beans</artifactId>
-		<version>5.2.3.RELEASE</version>
+		  <version>${spring.version}</version>
   	</dependency>
 
 	  <dependency>
 		  <groupId>org.springframework</groupId>
 		  <artifactId>spring-core</artifactId>
-		  <version>5.2.3.RELEASE</version>
+		  <version>${spring.version}</version>
 	  </dependency>
 
 	  <dependency>
 		  <groupId>org.springframework</groupId>
 		  <artifactId>spring-context</artifactId>
-		  <version>5.2.3.RELEASE</version>
+		  <version>${spring.version}</version>
 	  </dependency>
 
 	  <dependency>

+ 3 - 0
urule-parent/pom.xml

@@ -4,6 +4,9 @@
   <artifactId>urule-parent</artifactId>
   <version>2.0.4</version>
   <properties>
+	  <spring.version>5.3.31</spring.version>
+	  <spring.boot.version>2.7.18</spring.boot.version>
+
 	  <logback.version>1.2.12</logback.version>
 		<jaxb.version>2.3.0</jaxb.version>
 		<lombok.version>1.18.26</lombok.version>

+ 11 - 6
urule-springboot/pom.xml

@@ -7,6 +7,8 @@
 	<artifactId>urule-springboot</artifactId>
 	<version>2.1.8-SNAPSHOT</version>
 	<properties>
+	<spring.version>5.3.31</spring.version>
+	<spring.boot.version>2.7.18</spring.boot.version>
 		<fastjson.version>1.2.83</fastjson.version>
 
 		<java.main.class>com.bstek.urule.springboot.Application</java.main.class>
@@ -34,7 +36,7 @@
 	<parent>
 		<groupId>org.springframework.boot</groupId>
 		<artifactId>spring-boot-starter-parent</artifactId>
-		<version>2.2.4.RELEASE</version>
+		<version>2.7.18</version>
 		<relativePath />
 	</parent>
 	<dependencies>
@@ -71,12 +73,13 @@
 		<dependency>
 			<groupId>org.springframework</groupId>
 			<artifactId>spring-orm</artifactId>
-			<version>5.2.3.RELEASE</version>
+			<version>${spring.version}</version>
 		</dependency>
 
 		<dependency>
 			<groupId>org.springframework.boot</groupId>
 			<artifactId>spring-boot-starter-web</artifactId>
+			<version>${spring.boot.version}</version>
 			<exclusions>
 				<exclusion>
 					<artifactId>hibernate-validator</artifactId>
@@ -98,7 +101,7 @@
 		<dependency>
 			<groupId>com.alibaba</groupId>
 			<artifactId>druid-spring-boot-starter</artifactId>
-			<version>1.1.9</version>
+			<version>1.2.21</version>
 		</dependency>
 
 		<dependency>
@@ -112,12 +115,14 @@
 				</exclusion>
 			</exclusions>
 		</dependency>
+		
 		<dependency>
-			<groupId>javax.servlet</groupId>
-			<artifactId>servlet-api</artifactId>
-			<version>2.5</version>
+			<groupId>jakarta.servlet</groupId>
+			<artifactId>jakarta.servlet-api</artifactId>
+			<version>4.0.4</version>
 			<scope>provided</scope>
 		</dependency>
+
 	</dependencies>
 	<build>
 		<plugins>

+ 4 - 0
urule-springboot/src/main/resources/application.properties

@@ -23,3 +23,7 @@ spring.datasource.druid.min-evictable-idle-time-millis=100000
 #urule.console.title=EDAS Rule
 urule.repository.databasetype=mysql
 urule.repository.datasourcename=dataSource
+
+spring.main.allow-bean-definition-overriding=true
+#允许循环引用
+spring.main.allow-circular-references=true