Skip to content

Commit

Permalink
[Improve][Paimon] remove unwanted dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
dailai committed Mar 12, 2024
1 parent 937c7aa commit 408784f
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 51 deletions.
16 changes: 8 additions & 8 deletions docs/zh/connector-v2/sink/Paimon.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ Apache Paimon数据连接器。支持cdc写以及自动建表。

## 连接器选项

| 名称 | 类型 | 是否必须 | 默认值 | 描述 |
|------------------|--------|------|------------------------------|-------------------|
| warehouse | String | Yes | - | Paimon warehouse路 |
| database | String | Yes | - | 数据库名称 |
| table | String | Yes | - | 表名 |
| hdfs_site_path | String | No | - | |
| schema_save_mode | Enum | no | CREATE_SCHEMA_WHEN_NOT_EXIST | schema保存模式 |
| data_save_mode | Enum | no | APPEND_DATA | 数据保存模式 |
| 名称 | 类型 | 是否必须 | 默认值 | 描述 |
|------------------|--------|------|------------------------------|--------------------|
| warehouse | String | Yes | - | Paimon warehouse路径 |
| database | String | Yes | - | 数据库名称 |
| table | String | Yes | - | 表名 |
| hdfs_site_path | String | No | - | |
| schema_save_mode | Enum | no | CREATE_SCHEMA_WHEN_NOT_EXIST | schema保存模式 |
| data_save_mode | Enum | no | APPEND_DATA | 数据保存模式 |

## 示例

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,12 @@

import org.apache.paimon.table.Table;

import com.google.auto.service.AutoService;

import java.io.IOException;
import java.util.List;
import java.util.Optional;

import static org.apache.seatunnel.api.table.factory.FactoryUtil.discoverFactory;

@AutoService(SeaTunnelSink.class)
public class PaimonSink
implements SeaTunnelSink<
SeaTunnelRow,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,63 +25,29 @@
<artifactId>connector-paimon-e2e</artifactId>
<name>SeaTunnel : E2E : Connector V2 : Paimon</name>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.seatunnel</groupId>
<artifactId>connector-jdbc</artifactId>
<version>${project.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<groupId>org.apache.seatunnel</groupId>
<artifactId>connector-fake</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.seatunnel</groupId>
<artifactId>connector-paimon</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.seatunnel</groupId>
<artifactId>connector-assert</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>mysql</artifactId>
<version>${testcontainer.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.seatunnel</groupId>
<artifactId>connector-cdc-mysql</artifactId>
<version>${project.version}</version>
<artifactId>seatunnel-hadoop3-3.1.4-uber</artifactId>
<classifier>optional</classifier>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.apache.seatunnel</groupId>
<artifactId>connector-cdc-mysql</artifactId>
<artifactId>connector-assert</artifactId>
<version>${project.version}</version>
<type>test-jar</type>
<scope>test</scope>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.seatunnel</groupId>
<artifactId>seatunnel-hadoop3-3.1.4-uber</artifactId>
<classifier>optional</classifier>
<scope>test</scope>
</dependency>
</dependencies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
value = {},
type = {EngineType.SPARK, EngineType.FLINK},
disabledReason =
"Spark and Flink engine can not auto create paimon table on worker node(e.g flink tm) by org.apache.seatunnel.connectors.seatunnel.paimon.sink.PaimonSink.PaimonSink which can lead error")
"Spark and Flink engine can not auto create paimon table on worker node in local file(e.g flink tm) by savemode feature which can lead error")
@Slf4j
public class PaimonSinkCDCIT extends TestSuiteBase implements TestResource {
private static final String CATALOG_ROOT_DIR = "/tmp/";
Expand Down Expand Up @@ -190,7 +190,7 @@ private void extractFiles() {
"sh", "-c", "cd " + CATALOG_ROOT_DIR + " && tar -zxvf " + NAMESPACE_TAR);
try {
Process process = processBuilder.start();
// 等待命令执行完成
// wait command completed
int exitCode = process.waitFor();
if (exitCode == 0) {
log.info("Extract files successful.");
Expand Down

0 comments on commit 408784f

Please sign in to comment.