forked from github/dataease
Merge branch 'dev' into pr@dev_eslint_auto_fix
This commit is contained in:
commit
6f133774e6
@ -6,7 +6,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>dataease-server</artifactId>
|
<artifactId>dataease-server</artifactId>
|
||||||
<groupId>io.dataease</groupId>
|
<groupId>io.dataease</groupId>
|
||||||
<version>1.15.0</version>
|
<version>1.16.0</version>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
@ -205,7 +205,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>io.dataease</groupId>
|
<groupId>io.dataease</groupId>
|
||||||
<artifactId>dataease-plugin-interface</artifactId>
|
<artifactId>dataease-plugin-interface</artifactId>
|
||||||
<version>1.15.0</version>
|
<version>1.16.0</version>
|
||||||
<exclusions>
|
<exclusions>
|
||||||
<exclusion>
|
<exclusion>
|
||||||
<artifactId>guava</artifactId>
|
<artifactId>guava</artifactId>
|
||||||
@ -216,12 +216,12 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>io.dataease</groupId>
|
<groupId>io.dataease</groupId>
|
||||||
<artifactId>dataease-plugin-view</artifactId>
|
<artifactId>dataease-plugin-view</artifactId>
|
||||||
<version>1.15.0</version>
|
<version>1.16.0</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>io.dataease</groupId>
|
<groupId>io.dataease</groupId>
|
||||||
<artifactId>dataease-plugin-datasource</artifactId>
|
<artifactId>dataease-plugin-datasource</artifactId>
|
||||||
<version>1.15.0</version>
|
<version>1.16.0</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<!-- kettle及数据源依赖 -->
|
<!-- kettle及数据源依赖 -->
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -5,20 +5,30 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class MysqlConfiguration extends JdbcConfiguration {
|
public class MysqlConfiguration extends JdbcConfiguration {
|
||||||
|
|
||||||
private String driver = "com.mysql.jdbc.Driver";
|
private String driver = "com.mysql.jdbc.Driver";
|
||||||
private String extraParams = "characterEncoding=UTF-8&connectTimeout=5000&useSSL=false&allowPublicKeyRetrieval=true&zeroDateTimeBehavior=convertToNull";
|
private String extraParams = "characterEncoding=UTF-8&connectTimeout=5000&useSSL=false&allowPublicKeyRetrieval=true&zeroDateTimeBehavior=convertToNull";
|
||||||
|
private List<String> illegalParameters = Arrays.asList("autoDeserialize", "queryInterceptors", "statementInterceptors", "detectCustomCollations");
|
||||||
|
|
||||||
public String getJdbc() {
|
public String getJdbc() {
|
||||||
if(StringUtils.isEmpty(extraParams.trim())){
|
if (StringUtils.isEmpty(extraParams.trim())) {
|
||||||
return "jdbc:mysql://HOSTNAME:PORT/DATABASE"
|
return "jdbc:mysql://HOSTNAME:PORT/DATABASE"
|
||||||
.replace("HOSTNAME", getHost().trim())
|
.replace("HOSTNAME", getHost().trim())
|
||||||
.replace("PORT", getPort().toString().trim())
|
.replace("PORT", getPort().toString().trim())
|
||||||
.replace("DATABASE", getDataBase().trim());
|
.replace("DATABASE", getDataBase().trim());
|
||||||
}else {
|
} else {
|
||||||
|
for (String illegalParameter : illegalParameters) {
|
||||||
|
if (getExtraParams().contains(illegalParameter)) {
|
||||||
|
throw new RuntimeException("Illegal parameter: " + illegalParameter);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return "jdbc:mysql://HOSTNAME:PORT/DATABASE?EXTRA_PARAMS"
|
return "jdbc:mysql://HOSTNAME:PORT/DATABASE?EXTRA_PARAMS"
|
||||||
.replace("HOSTNAME", getHost().trim())
|
.replace("HOSTNAME", getHost().trim())
|
||||||
.replace("PORT", getPort().toString().trim())
|
.replace("PORT", getPort().toString().trim())
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "dataease",
|
"name": "dataease",
|
||||||
"version": "1.15.0",
|
"version": "1.16.0",
|
||||||
"description": "dataease front",
|
"description": "dataease front",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>dataease-server</artifactId>
|
<artifactId>dataease-server</artifactId>
|
||||||
<groupId>io.dataease</groupId>
|
<groupId>io.dataease</groupId>
|
||||||
<version>1.15.0</version>
|
<version>1.16.0</version>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "dataease-mobile",
|
"name": "dataease-mobile",
|
||||||
"version": "1.15.0",
|
"version": "1.16.0",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"serve": "npm run dev:h5",
|
"serve": "npm run dev:h5",
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<artifactId>dataease-server</artifactId>
|
<artifactId>dataease-server</artifactId>
|
||||||
<groupId>io.dataease</groupId>
|
<groupId>io.dataease</groupId>
|
||||||
<version>1.15.0</version>
|
<version>1.16.0</version>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
2
pom.xml
2
pom.xml
@ -5,7 +5,7 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<groupId>io.dataease</groupId>
|
<groupId>io.dataease</groupId>
|
||||||
<artifactId>dataease-server</artifactId>
|
<artifactId>dataease-server</artifactId>
|
||||||
<version>1.15.0</version>
|
<version>1.16.0</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
|
Loading…
Reference in New Issue
Block a user