diff --git a/Dockerfile b/Dockerfile
index 60f8be90..6796a52b 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,10 +1,9 @@
-FROM java:8
+FROM eclipse-temurin:8-jdk-focal
MAINTAINER qianmoQ "shicheng@ttxit.com"
# Add datacap
RUN mkdir -p /opt/app
-COPY dist/datacap-release.tar.gz /opt/app/datacap-release.tar.gz
-RUN tar -xvzf /opt/app/datacap-release.tar.gz -C /opt/app/
+ADD dist/datacap-release.tar.gz /opt/app/
WORKDIR /opt/app/datacap
CMD sh ./bin/startup.sh
diff --git a/plugin/jdbc/kyuubi/pom.xml b/plugin/jdbc/kyuubi/pom.xml
index 845acbb6..66392230 100644
--- a/plugin/jdbc/kyuubi/pom.xml
+++ b/plugin/jdbc/kyuubi/pom.xml
@@ -13,7 +13,7 @@
DataCap plugin for jdbc (Kyuubi)
- 1.5.2-incubating
+ 1.6.0-incubating
jdbc-kyuubi
diff --git a/server/src/main/java/io/edurt/datacap/server/common/PluginCommon.java b/server/src/main/java/io/edurt/datacap/server/common/PluginCommon.java
new file mode 100644
index 00000000..c4b2a5c2
--- /dev/null
+++ b/server/src/main/java/io/edurt/datacap/server/common/PluginCommon.java
@@ -0,0 +1,23 @@
+package io.edurt.datacap.server.common;
+
+import com.google.inject.Injector;
+import com.google.inject.Key;
+import com.google.inject.TypeLiteral;
+import io.edurt.datacap.spi.Plugin;
+
+import java.util.Optional;
+import java.util.Set;
+
+public class PluginCommon
+{
+ private PluginCommon() {}
+
+ public static Optional getPluginByName(Injector injector, String pluginName)
+ {
+ Optional pluginOptional = injector.getInstance(Key.get(new TypeLiteral>() {}))
+ .stream()
+ .filter(plugin -> plugin.name().equalsIgnoreCase(pluginName))
+ .findFirst();
+ return pluginOptional;
+ }
+}
diff --git a/server/src/main/java/io/edurt/datacap/server/entity/SourceEntity.java b/server/src/main/java/io/edurt/datacap/server/entity/SourceEntity.java
index c8f4573a..0a65a80f 100644
--- a/server/src/main/java/io/edurt/datacap/server/entity/SourceEntity.java
+++ b/server/src/main/java/io/edurt/datacap/server/entity/SourceEntity.java
@@ -78,6 +78,10 @@ public class SourceEntity
@Column(name = "create_time", columnDefinition = "datetime default CURRENT_TIMESTAMP()")
private Timestamp createTime;
+ // Add from 1.1.0.20221115
+ @Column(name = "_ssl", columnDefinition = "boolean default false")
+ private Boolean ssl;
+
@OneToMany(mappedBy = "plugin", cascade = CascadeType.REMOVE, fetch = FetchType.LAZY)
@JsonIgnore
private List pluginAudits;
diff --git a/server/src/main/java/io/edurt/datacap/server/service/impl/ExecuteServiceImpl.java b/server/src/main/java/io/edurt/datacap/server/service/impl/ExecuteServiceImpl.java
index 81193ffe..d65bc001 100644
--- a/server/src/main/java/io/edurt/datacap/server/service/impl/ExecuteServiceImpl.java
+++ b/server/src/main/java/io/edurt/datacap/server/service/impl/ExecuteServiceImpl.java
@@ -1,9 +1,8 @@
package io.edurt.datacap.server.service.impl;
import com.google.inject.Injector;
-import com.google.inject.Key;
-import com.google.inject.TypeLiteral;
import io.edurt.datacap.server.audit.AuditPlugin;
+import io.edurt.datacap.server.common.PluginCommon;
import io.edurt.datacap.server.common.Response;
import io.edurt.datacap.server.common.ServiceState;
import io.edurt.datacap.server.entity.ExecuteEntity;
@@ -15,7 +14,6 @@ import io.edurt.datacap.spi.model.Configure;
import org.springframework.stereotype.Service;
import java.util.Optional;
-import java.util.Set;
@Service
public class ExecuteServiceImpl
@@ -40,10 +38,7 @@ public class ExecuteServiceImpl
}
SourceEntity entity = entityOptional.get();
- Optional pluginOptional = this.injector.getInstance(Key.get(new TypeLiteral>() {}))
- .stream()
- .filter(plugin -> plugin.name().equalsIgnoreCase(entity.getType()))
- .findFirst();
+ Optional pluginOptional = PluginCommon.getPluginByName(this.injector, entity.getType());
if (!pluginOptional.isPresent()) {
return Response.failure(ServiceState.PLUGIN_NOT_FOUND);
}
@@ -55,6 +50,7 @@ public class ExecuteServiceImpl
_configure.setUsername(Optional.ofNullable(entity.getUsername()));
_configure.setPassword(Optional.ofNullable(entity.getPassword()));
_configure.setDatabase(Optional.ofNullable(entity.getDatabase()));
+ _configure.setSsl(Optional.ofNullable(entity.getSsl()));
_configure.setEnv(Optional.ofNullable(configure.getEnv()));
_configure.setFormat(configure.getFormat());
plugin.connect(_configure);
diff --git a/server/src/main/java/io/edurt/datacap/server/service/impl/SourceServiceImpl.java b/server/src/main/java/io/edurt/datacap/server/service/impl/SourceServiceImpl.java
index 0fa31716..be502508 100644
--- a/server/src/main/java/io/edurt/datacap/server/service/impl/SourceServiceImpl.java
+++ b/server/src/main/java/io/edurt/datacap/server/service/impl/SourceServiceImpl.java
@@ -4,6 +4,7 @@ import com.google.inject.Injector;
import com.google.inject.Key;
import com.google.inject.TypeLiteral;
import io.edurt.datacap.server.adapter.PageRequestAdapter;
+import io.edurt.datacap.server.common.PluginCommon;
import io.edurt.datacap.server.common.Response;
import io.edurt.datacap.server.common.ServiceState;
import io.edurt.datacap.server.entity.PageEntity;
@@ -59,10 +60,7 @@ public class SourceServiceImpl
@Override
public Response