rdblue commented on a change in pull request #3135:
URL: https://github.com/apache/iceberg/pull/3135#discussion_r714195431



##########
File path: data/src/test/java/org/apache/iceberg/data/DeleteReadTests.java
##########
@@ -330,6 +420,15 @@ private StructLikeSet rowSetWithoutIds(int... idsToRemove) 
{
     return set;
   }
 
+  private StructLikeSet rowSetWithoutIds(Set<Integer> idSet, Table iTable, 
List<Record> recordList) {
+    StructLikeSet set = StructLikeSet.create(iTable.schema().asStruct());
+    recordList.stream()
+        .filter(row -> !idSet.contains(row.getField("id")))
+        .map(record -> new 
InternalRecordWrapper(iTable.schema().asStruct()).wrap(record))
+        .forEach(set::add);
+    return set;
+  }

Review comment:
       I think the other `rowSetWithoutIds` method should be rewritten to call 
this one since it is more generic. That will also avoid the wrapper problem in 
the future.




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