openinx commented on a change in pull request #1802:
URL: https://github.com/apache/iceberg/pull/1802#discussion_r528289582



##########
File path: 
core/src/main/java/org/apache/iceberg/io/UnpartitionedDeltaWriter.java
##########
@@ -0,0 +1,47 @@
+/*
+ * Licensed 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.iceberg.io;
+
+import java.io.IOException;
+import org.apache.iceberg.FileFormat;
+import org.apache.iceberg.PartitionSpec;
+
+public class UnpartitionedDeltaWriter<T> extends BaseTaskWriter<T> {

Review comment:
       I think we would still need to add an extra `DeltaWriter`  between the 
`TaskWriter` and `RollingFileWriter`s, because for a fanout `TaskWriter`, it 
will have rows from different partitions or buckets, and the writer for 
different  partitions(or buckets) would accept data record,  equality deletions 
, which is named `DeltaWriter`. 
   
   In this way,  we could move all the equality delete logics inside a single 
common `DeltaWriter` class,  and the `TaskWriter` will focus on how to dispatch 
the records with the customized policy to the methods in `DeltaWriter`, for 
example,  Flink's RowData has INSERT/DELETE/UPDATE_BEFORE/UPDATE_AFTER,  if the 
row is   a DELETE, then could use the fanout policy to direct it to 
`DeltaWriter`'s  `delete` method. 




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

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