You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@paimon.apache.org by lz...@apache.org on 2024/03/13 08:39:55 UTC
(incubator-paimon) branch master updated: [hotfix] Remove useless 'write-mode' option in tests (#3000)
This is an automated email from the ASF dual-hosted git repository.
lzljs3620320 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-paimon.git
The following commit(s) were added to refs/heads/master by this push:
new 384c6e75d [hotfix] Remove useless 'write-mode' option in tests (#3000)
384c6e75d is described below
commit 384c6e75dfe5099f32e641024caa2c6ad72b08cb
Author: yuzelin <33...@users.noreply.github.com>
AuthorDate: Wed Mar 13 16:39:50 2024 +0800
[hotfix] Remove useless 'write-mode' option in tests (#3000)
---
.../apache/paimon/flink/AppendOnlyTableITCase.java | 2 +-
.../org/apache/paimon/spark/PaimonSinkTest.scala | 20 ++++++++++----------
.../spark/sql/CreateAndDeleteTagProcedureTest.scala | 4 ++--
.../paimon/spark/sql/RollbackProcedureTest.scala | 4 ++--
4 files changed, 15 insertions(+), 15 deletions(-)
diff --git a/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/AppendOnlyTableITCase.java b/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/AppendOnlyTableITCase.java
index 11a6b941f..95defcd42 100644
--- a/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/AppendOnlyTableITCase.java
+++ b/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/AppendOnlyTableITCase.java
@@ -245,7 +245,7 @@ public class AppendOnlyTableITCase extends CatalogITCaseBase {
@Test
public void testDynamicOptions() throws Exception {
- sql("CREATE TABLE T (id INT) WITH ('write-mode'='append-only')");
+ sql("CREATE TABLE T (id INT)");
batchSql("INSERT INTO T VALUES (1)");
sEnv.getConfig()
.getConfiguration()
diff --git a/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/PaimonSinkTest.scala b/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/PaimonSinkTest.scala
index 9123a5b4b..f568a0838 100644
--- a/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/PaimonSinkTest.scala
+++ b/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/PaimonSinkTest.scala
@@ -33,10 +33,10 @@ class PaimonSinkTest extends PaimonSparkTestBase with StreamTest {
failAfter(streamingTimeout) {
withTempDir {
checkpointDir =>
- // define a change-log table and test `forEachBatch` api
+ // define a pk table and test `forEachBatch` api
spark.sql(s"""
|CREATE TABLE T (a INT, b STRING)
- |TBLPROPERTIES ('primary-key'='a', 'write-mode'='change-log', 'bucket'='3')
+ |TBLPROPERTIES ('primary-key'='a', 'bucket'='3')
|""".stripMargin)
val location = loadTable("T").location().toString
@@ -77,10 +77,10 @@ class PaimonSinkTest extends PaimonSparkTestBase with StreamTest {
failAfter(streamingTimeout) {
withTempDir {
checkpointDir =>
- // define a change-log table and sink into it in append mode
+ // define a pk table and sink into it in append mode
spark.sql(s"""
|CREATE TABLE T (a INT, b STRING)
- |TBLPROPERTIES ('primary-key'='a', 'write-mode'='change-log', 'bucket'='3')
+ |TBLPROPERTIES ('primary-key'='a', 'bucket'='3')
|""".stripMargin)
val location = loadTable("T").location().toString
@@ -121,7 +121,7 @@ class PaimonSinkTest extends PaimonSparkTestBase with StreamTest {
// define an append-only table and sink into it in complete mode
spark.sql(s"""
|CREATE TABLE T (city String, population Long)
- |TBLPROPERTIES ('write-mode'='append-only', 'bucket'='3')
+ |TBLPROPERTIES ('bucket'='3')
|""".stripMargin)
val location = loadTable("T").location().toString
@@ -162,10 +162,10 @@ class PaimonSinkTest extends PaimonSparkTestBase with StreamTest {
failAfter(streamingTimeout) {
withTempDir {
checkpointDir =>
- // define a change-log table and sink into it in update mode
+ // define a pk table and sink into it in update mode
spark.sql(s"""
|CREATE TABLE T (a INT, b STRING)
- |TBLPROPERTIES ('primary-key'='a', 'write-mode'='change-log', 'bucket'='3')
+ |TBLPROPERTIES ('primary-key'='a', 'bucket'='3')
|""".stripMargin)
val location = loadTable("T").location().toString
@@ -189,7 +189,7 @@ class PaimonSinkTest extends PaimonSparkTestBase with StreamTest {
// define an append-only table and sink into it with aggregation and watermark in append mode
spark.sql(s"""
|CREATE TABLE T (start Timestamp, stockId INT, avg_price DOUBLE)
- |TBLPROPERTIES ('write-mode'='append-only', 'bucket'='3')
+ |TBLPROPERTIES ('bucket'='3')
|""".stripMargin)
val location = loadTable("T").location().toString
@@ -237,10 +237,10 @@ class PaimonSinkTest extends PaimonSparkTestBase with StreamTest {
failAfter(streamingTimeout) {
withTempDir {
checkpointDir =>
- // define a change-log table and sink into it with schema evolution in append mode
+ // define a pk table and sink into it with schema evolution in append mode
spark.sql(s"""
|CREATE TABLE T (a INT, b STRING)
- |TBLPROPERTIES ('primary-key'='a', 'write-mode'='change-log', 'bucket'='3')
+ |TBLPROPERTIES ('primary-key'='a', 'bucket'='3')
|""".stripMargin)
val location = loadTable("T").location().toString
diff --git a/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/sql/CreateAndDeleteTagProcedureTest.scala b/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/sql/CreateAndDeleteTagProcedureTest.scala
index f40030b51..a654da55a 100644
--- a/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/sql/CreateAndDeleteTagProcedureTest.scala
+++ b/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/sql/CreateAndDeleteTagProcedureTest.scala
@@ -32,10 +32,10 @@ class CreateAndDeleteTagProcedureTest extends PaimonSparkTestBase with StreamTes
failAfter(streamingTimeout) {
withTempDir {
checkpointDir =>
- // define a change-log table and test `forEachBatch` api
+ // define a pk table and test `forEachBatch` api
spark.sql(s"""
|CREATE TABLE T (a INT, b STRING)
- |TBLPROPERTIES ('primary-key'='a', 'write-mode'='change-log', 'bucket'='3')
+ |TBLPROPERTIES ('primary-key'='a', 'bucket'='3')
|""".stripMargin)
val location = loadTable("T").location().toString
diff --git a/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/sql/RollbackProcedureTest.scala b/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/sql/RollbackProcedureTest.scala
index 62244be7c..7a3a5730e 100644
--- a/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/sql/RollbackProcedureTest.scala
+++ b/paimon-spark/paimon-spark-3.4/src/test/scala/org/apache/paimon/spark/sql/RollbackProcedureTest.scala
@@ -32,10 +32,10 @@ class RollbackProcedureTest extends PaimonSparkTestBase with StreamTest {
failAfter(streamingTimeout) {
withTempDir {
checkpointDir =>
- // define a change-log table and test `forEachBatch` api
+ // define a pk table and test `forEachBatch` api
spark.sql(s"""
|CREATE TABLE T (a INT, b STRING)
- |TBLPROPERTIES ('primary-key'='a', 'write-mode'='change-log', 'bucket'='3')
+ |TBLPROPERTIES ('primary-key'='a', 'bucket'='3')
|""".stripMargin)
val location = loadTable("T").location().toString