From 44bb654c5e79e2989ac69352193ce5791aa43804 Mon Sep 17 00:00:00 2001
From: BaoLiang <29528966+lenboo@users.noreply.github.com>
Date: Wed, 2 Mar 2022 16:10:39 +0800
Subject: [PATCH] Revert "upgrade mybatis-plus to 3.4.3 (#8515)" (#8659)
This reverts commit ca6d148a1b48195a359a3ab29d449229a87dd05a.
---
.../dao/datasource/SpringConnectionFactory.java | 16 ++++++++--------
dolphinscheduler-dist/release-docs/LICENSE | 16 ++++++++--------
pom.xml | 4 ++--
tools/dependencies/known-dependencies.txt | 16 ++++++++--------
4 files changed, 26 insertions(+), 26 deletions(-)
diff --git a/dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/datasource/SpringConnectionFactory.java b/dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/datasource/SpringConnectionFactory.java
index 600a062f3d..516e16ad42 100644
--- a/dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/datasource/SpringConnectionFactory.java
+++ b/dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/datasource/SpringConnectionFactory.java
@@ -35,14 +35,17 @@ import org.springframework.jdbc.datasource.DataSourceTransactionManager;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.core.MybatisConfiguration;
import com.baomidou.mybatisplus.core.config.GlobalConfig;
-import com.baomidou.mybatisplus.extension.MybatisMapWrapperFactory;
-import com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor;
-import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
+import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor;
import com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean;
@Configuration
public class SpringConnectionFactory {
+ @Bean
+ public PaginationInterceptor paginationInterceptor() {
+ return new PaginationInterceptor();
+ }
+
@Bean
public DataSourceTransactionManager transactionManager(DataSource dataSource) {
return new DataSourceTransactionManager(dataSource);
@@ -55,15 +58,12 @@ public class SpringConnectionFactory {
configuration.setCacheEnabled(false);
configuration.setCallSettersOnNulls(true);
configuration.setJdbcTypeForNull(JdbcType.NULL);
- configuration.setObjectWrapperFactory(new MybatisMapWrapperFactory());
-
- MybatisPlusInterceptor mybatisPlusInterceptor = new MybatisPlusInterceptor();
- mybatisPlusInterceptor.addInnerInterceptor(new PaginationInnerInterceptor());
+ configuration.addInterceptor(paginationInterceptor());
+ configuration.setGlobalConfig(new GlobalConfig().setBanner(false));
MybatisSqlSessionFactoryBean sqlSessionFactoryBean = new MybatisSqlSessionFactoryBean();
sqlSessionFactoryBean.setConfiguration(configuration);
sqlSessionFactoryBean.setDataSource(dataSource);
- sqlSessionFactoryBean.setPlugins(mybatisPlusInterceptor);
GlobalConfig.DbConfig dbConfig = new GlobalConfig.DbConfig();
dbConfig.setIdType(IdType.AUTO);
diff --git a/dolphinscheduler-dist/release-docs/LICENSE b/dolphinscheduler-dist/release-docs/LICENSE
index 46301441cb..ac654dde6b 100644
--- a/dolphinscheduler-dist/release-docs/LICENSE
+++ b/dolphinscheduler-dist/release-docs/LICENSE
@@ -323,7 +323,7 @@ The text of each license is also included at licenses/LICENSE-[project].txt.
jna-platform 5.10.0: https://mvnrepository.com/artifact/net.java.dev.jna/jna-platform/5.10.0, Apache 2.0 and LGPL 2.1
joda-time 2.10.13: https://github.com/JodaOrg/joda-time, Apache 2.0
jpam 1.1: https://mvnrepository.com/artifact/net.sf.jpam/jpam/1.1, Apache 2.0
- jsqlparser 4.0: https://github.com/JSQLParser/JSqlParser, Apache 2.0 or LGPL 2.1
+ jsqlparser 2.1: https://github.com/JSQLParser/JSqlParser, Apache 2.0 or LGPL 2.1
jsr305 3.0.0: https://mvnrepository.com/artifact/com.google.code.findbugs/jsr305, Apache 2.0
j2objc-annotations 1.1 https://mvnrepository.com/artifact/com.google.j2objc/j2objc-annotations/1.1, Apache 2.0
libfb303 0.9.3: https://mvnrepository.com/artifact/org.apache.thrift/libfb303/0.9.3, Apache 2.0
@@ -334,13 +334,13 @@ The text of each license is also included at licenses/LICENSE-[project].txt.
log4j-1.2-api 2.14.1: https://mvnrepository.com/artifact/org.apache.logging.log4j/log4j-1.2-api/2.14.1, Apache 2.0
lz4 1.3.0: https://mvnrepository.com/artifact/net.jpountz.lz4/lz4/1.3.0, Apache 2.0
mapstruct 1.2.0.Final: https://github.com/mapstruct/mapstruct, Apache 2.0
- mybatis 3.5.7 https://mvnrepository.com/artifact/org.mybatis/mybatis/3.5.7, Apache 2.0
- mybatis-plus 3.4.3: https://github.com/baomidou/mybatis-plus, Apache 2.0
- mybatis-plus-annotation 3.4.3: https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-annotation/3.4.3, Apache 2.0
- mybatis-plus-boot-starter 3.4.3: https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-boot-starter/3.4.3, Apache 2.0
- mybatis-plus-core 3.4.3: https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-core/3.4.3, Apache 2.0
- mybatis-plus-extension 3.4.3: https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-extension/3.4.3, Apache 2.0
- mybatis-spring 2.0.6: https://mvnrepository.com/artifact/org.mybatis/mybatis-spring/2.0.6, Apache 2.0
+ mybatis 3.5.2 https://mvnrepository.com/artifact/org.mybatis/mybatis/3.5.2, Apache 2.0
+ mybatis-plus 3.2.0: https://github.com/baomidou/mybatis-plus, Apache 2.0
+ mybatis-plus-annotation 3.2.0: https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-annotation/3.2.0, Apache 2.0
+ mybatis-plus-boot-starter 3.2.0: https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-boot-starter/3.2.0, Apache 2.0
+ mybatis-plus-core 3.2.0: https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-core/3.2.0, Apache 2.0
+ mybatis-plus-extension 3.2.0: https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-extension/3.2.0, Apache 2.0
+ mybatis-spring 2.0.2: https://mvnrepository.com/artifact/org.mybatis/mybatis-spring/2.0.2, Apache 2.0
netty 3.6.2.Final: https://github.com/netty/netty, Apache 2.0
netty 4.1.53.Final: https://github.com/netty/netty/blob/netty-4.1.53.Final/LICENSE.txt, Apache 2.0
opencsv 2.3: https://mvnrepository.com/artifact/net.sf.opencsv/opencsv/2.3, Apache 2.0
diff --git a/pom.xml b/pom.xml
index 0647e3f0c3..25c8648cf6 100644
--- a/pom.xml
+++ b/pom.xml
@@ -60,8 +60,8 @@