rdblue commented on code in PR #18138:
URL: https://github.com/apache/iceberg/pull/18138#discussion_r4031508478


##########
core/src/test/java/org/apache/iceberg/V4TestComparators.java:
##########
@@ -119,8 +119,7 @@ private static <T extends Comparable<T>> Comparator<T> 
natural() {
               .thenComparingLong(ManifestInfo::deletedRowsCount)
               .thenComparingLong(ManifestInfo::replacedRowsCount)
               .thenComparingLong(ManifestInfo::minSequenceNumber)
-              .thenComparing(ManifestInfo::dv, BYTES)
-              .thenComparing(ManifestInfo::dvCardinality, natural()));
+              .thenComparing(V4TestComparators::manifestDeletionVectorBuffer, 
BYTES));

Review Comment:
   I don't think that this needs to add a custom method. The `Comparator` API 
can handle this, and then we have a comparator that can be reused for 
`Tracking` later:
   
   ```java
     private static final Comparator<ManifestBitmap> BITMAPS =
         Comparator.nullsFirst(Comparator.comparing(ManifestBitmap::buffer, 
BYTES));
     ...
       .thenComparing(ManifestInfo::manifestDeletionVector, BITMAPS));
   ```



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