mxm commented on code in PR #15780:
URL: https://github.com/apache/iceberg/pull/15780#discussion_r3022473989


##########
flink/v2.1/flink/src/main/java/org/apache/iceberg/flink/sink/dynamic/DynamicRecord.java:
##########
@@ -141,4 +152,12 @@ public Set<String> equalityFields() {
   public void setEqualityFields(Set<String> equalityFields) {
     this.equalityFields = equalityFields;
   }
+
+  public void setFlinkWriteConf(FlinkWriteConf flinkWriteConf) {
+    this.flinkWriteConf = flinkWriteConf;
+  }
+
+  public FlinkWriteConf flinkWriteConf() {
+    return flinkWriteConf;
+  }

Review Comment:
   Do we want those methods to be public? We could make them package-private.
   
   ```suggestion
     void setFlinkWriteConf(FlinkWriteConf flinkWriteConf) {
       this.flinkWriteConf = flinkWriteConf;
     }
   
     FlinkWriteConf flinkWriteConf() {
       return flinkWriteConf;
     }
   ```



##########
flink/v2.1/flink/src/main/java/org/apache/iceberg/flink/sink/dynamic/DynamicRecordProcessor.java:
##########
@@ -112,6 +119,9 @@ public void processElement(T element, Context ctx, 
Collector<DynamicRecordIntern
 
   @Override
   public void collect(DynamicRecord data) {
+    // Use configs to fallback, when not set on Dynamic Record.
+    data.setFlinkWriteConf(flinkWriteConf);

Review Comment:
   ```suggestion
       // Config to load values not set on Dynamic Record.
       data.setFlinkWriteConf(flinkWriteConf);
   ```



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to