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 2023/06/20 02:40:56 UTC

[incubator-paimon] branch release-0.4 updated (10a15e86a -> dec6cdec8)

This is an automated email from the ASF dual-hosted git repository.

lzljs3620320 pushed a change to branch release-0.4
in repository https://gitbox.apache.org/repos/asf/incubator-paimon.git


 discard 10a15e86a [flink] Fix kafka hybrid restore enumerator (#1263)
 discard a614a0503 [hotfix] Add icon for Paimon in IntellijIdea (#1265)
 discard 4473585c3 [core] Skip more unwanted merges for Manifest full compaction (#1268)
 discard 14307a952 [core] add FullCompaction for Manifest File (#1199)
     new 7889fc80b [flink] Fix kafka hybrid restore enumerator (#1263)
     new dec6cdec8 [hotfix] Add icon for Paimon in IntellijIdea (#1265)

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (10a15e86a)
            \
             N -- N -- N   refs/heads/release-0.4 (dec6cdec8)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../shortcodes/generated/core_configuration.html   |   6 -
 .../utils/RowDataToObjectArrayConverter.java       |  16 --
 .../java/org/apache/paimon/AbstractFileStore.java  |   1 -
 .../main/java/org/apache/paimon/CoreOptions.java   |  11 -
 .../org/apache/paimon/manifest/ManifestEntry.java  |   8 +-
 .../apache/paimon/manifest/ManifestFileMeta.java   | 248 ++----------------
 .../paimon/operation/AbstractFileStoreScan.java    |  13 +-
 .../paimon/operation/FileStoreCommitImpl.java      |   7 +-
 .../paimon/manifest/ManifestFileMetaTest.java      | 282 +++++++--------------
 .../paimon/manifest/ManifestFileMetaTestBase.java  | 224 ----------------
 .../manifest/NoPartitionManifestFileMetaTest.java  |  65 -----
 11 files changed, 126 insertions(+), 755 deletions(-)
 delete mode 100644 paimon-core/src/test/java/org/apache/paimon/manifest/ManifestFileMetaTestBase.java
 delete mode 100644 paimon-core/src/test/java/org/apache/paimon/manifest/NoPartitionManifestFileMetaTest.java


[incubator-paimon] 01/02: [flink] Fix kafka hybrid restore enumerator (#1263)

Posted by lz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

lzljs3620320 pushed a commit to branch release-0.4
in repository https://gitbox.apache.org/repos/asf/incubator-paimon.git

commit 7889fc80b1c3852f46fb13122908adde74124957
Author: Jingsong Lee <ji...@gmail.com>
AuthorDate: Wed May 31 09:55:23 2023 +0800

    [flink] Fix kafka hybrid restore enumerator (#1263)
---
 .../flink/source/LogHybridSourceFactory.java       |  8 ++--
 .../paimon/flink/kafka/KafkaLogTestUtils.java      |  2 +-
 .../flink/source/LogHybridSourceFactoryTest.java   | 44 ++++++++++++++++++++++
 3 files changed, 50 insertions(+), 4 deletions(-)

diff --git a/paimon-flink/paimon-flink-common/src/main/java/org/apache/paimon/flink/source/LogHybridSourceFactory.java b/paimon-flink/paimon-flink-common/src/main/java/org/apache/paimon/flink/source/LogHybridSourceFactory.java
index ef2dac7c1..4a2e91df8 100644
--- a/paimon-flink/paimon-flink-common/src/main/java/org/apache/paimon/flink/source/LogHybridSourceFactory.java
+++ b/paimon-flink/paimon-flink-common/src/main/java/org/apache/paimon/flink/source/LogHybridSourceFactory.java
@@ -56,10 +56,12 @@ public class LogHybridSourceFactory
     public Source<RowData, ?, ?> create(
             HybridSource.SourceSwitchContext<StaticFileStoreSplitEnumerator> context) {
         StaticFileStoreSplitEnumerator enumerator = context.getPreviousEnumerator();
-        Snapshot snapshot = enumerator.snapshot();
         Map<Integer, Long> logOffsets = null;
-        if (snapshot != null) {
-            logOffsets = snapshot.logOffsets();
+        if (enumerator != null) {
+            Snapshot snapshot = enumerator.snapshot();
+            if (snapshot != null) {
+                logOffsets = snapshot.logOffsets();
+            }
         }
         return provider.createSource(logOffsets);
     }
diff --git a/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/kafka/KafkaLogTestUtils.java b/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/kafka/KafkaLogTestUtils.java
index eb2201f15..583c69e77 100644
--- a/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/kafka/KafkaLogTestUtils.java
+++ b/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/kafka/KafkaLogTestUtils.java
@@ -161,7 +161,7 @@ public class KafkaLogTestUtils {
                 origin, new ResolvedSchema(resolvedColumns, Collections.emptyList(), constraint));
     }
 
-    static DynamicTableFactory.Context testContext(
+    public static DynamicTableFactory.Context testContext(
             String servers, LogChangelogMode changelogMode, boolean keyed) {
         return testContext("table", servers, changelogMode, LogConsistency.TRANSACTIONAL, keyed);
     }
diff --git a/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/source/LogHybridSourceFactoryTest.java b/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/source/LogHybridSourceFactoryTest.java
new file mode 100644
index 000000000..5751495d4
--- /dev/null
+++ b/paimon-flink/paimon-flink-common/src/test/java/org/apache/paimon/flink/source/LogHybridSourceFactoryTest.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.paimon.flink.source;
+
+import org.apache.paimon.CoreOptions;
+import org.apache.paimon.flink.kafka.KafkaLogSourceProvider;
+import org.apache.paimon.flink.kafka.KafkaLogTestUtils;
+
+import org.junit.jupiter.api.Test;
+
+import static org.apache.paimon.flink.kafka.KafkaLogTestUtils.discoverKafkaLogFactory;
+import static org.apache.paimon.flink.kafka.KafkaLogTestUtils.testContext;
+
+/** Test for {@link LogHybridSourceFactory}. */
+public class LogHybridSourceFactoryTest {
+
+    @Test
+    public void testRestoreLogSource() {
+        KafkaLogSourceProvider sourceProvider =
+                discoverKafkaLogFactory()
+                        .createSourceProvider(
+                                testContext("", CoreOptions.LogChangelogMode.UPSERT, true),
+                                KafkaLogTestUtils.SOURCE_CONTEXT,
+                                null);
+        LogHybridSourceFactory sourceFactory = new LogHybridSourceFactory(sourceProvider);
+        sourceFactory.create(() -> null);
+    }
+}


[incubator-paimon] 02/02: [hotfix] Add icon for Paimon in IntellijIdea (#1265)

Posted by lz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

lzljs3620320 pushed a commit to branch release-0.4
in repository https://gitbox.apache.org/repos/asf/incubator-paimon.git

commit dec6cdec81f162e0d63ac82a1f89d8b55155ae34
Author: Kerwin <37...@users.noreply.github.com>
AuthorDate: Wed May 31 10:18:16 2023 +0800

    [hotfix] Add icon for Paimon in IntellijIdea (#1265)
---
 .gitignore     |   1 +
 .idea/icon.png | Bin 0 -> 5953 bytes
 2 files changed, 1 insertion(+)

diff --git a/.gitignore b/.gitignore
index d2e9c21ad..3831eb7e9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,6 +2,7 @@
 .classpath
 .idea/*
 !.idea/vcs.xml
+!.idea/icon.png
 .metadata
 .settings
 .project
diff --git a/.idea/icon.png b/.idea/icon.png
new file mode 100644
index 000000000..d1c401d84
Binary files /dev/null and b/.idea/icon.png differ