JingsongLi commented on code in PR #829:
URL: https://github.com/apache/incubator-paimon/pull/829#discussion_r1160390550


##########
paimon-flink/paimon-flink-common/src/main/java/org/apache/paimon/flink/action/ActionBase.java:
##########
@@ -147,4 +151,20 @@ protected void batchSink(DataStream<RowData> dataStream) {
 
         TableEnvironmentUtils.executeInternal(tEnv, transformations, 
sinkIdentifierNames);
     }
+
+    /**
+     * The {@link CoreOptions.MergeEngine}s will process -U/-D records in 
different ways, but we
+     * want these records to be sunk directly. This method is a workaround. 
Actions that may produce
+     * -U/-D records can call this to disable merge engine settings and force 
compaction.
+     */
+    protected void forceSinking() {
+        Map<String, String> dynamicOptions = new HashMap<>();
+        dynamicOptions.put(
+                CoreOptions.MERGE_ENGINE.key(), 
CoreOptions.MergeEngine.DEDUPLICATE.toString());

Review Comment:
   only to non-DEDUPLICATE engines. Need to set `FULL_COMPACTION_DELTA_COMMITS`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to