yihua commented on code in PR #13523:
URL: https://github.com/apache/hudi/pull/13523#discussion_r2231030966


##########
hudi-common/src/main/java/org/apache/hudi/metadata/HoodieBackedTableMetadata.java:
##########
@@ -631,6 +603,28 @@ private <T> ClosableIterator<T> lookupRecords(List<String> 
sortedKeys,
     }
   }
 
+  static Predicate buildPredicate(String partitionName, List<String> 
sortedKeys, boolean isFullKey) {
+    if (MetadataPartitionType.fromPartitionPath(partitionName)
+          .equals(MetadataPartitionType.SECONDARY_INDEX)) {
+      // For secondary index, always use prefix matching

Review Comment:
   We need to revisit how secondary index read calls lookup APIs as a 
follow-up.  It looks unintuitive to pass `fullKey` as `true` for secondary 
index.



##########
hudi-common/src/main/java/org/apache/hudi/metadata/HoodieBackedTableMetadata.java:
##########
@@ -631,6 +603,28 @@ private <T> ClosableIterator<T> lookupRecords(List<String> 
sortedKeys,
     }
   }
 
+  static Predicate buildPredicate(String partitionName, List<String> 
sortedKeys, boolean isFullKey) {
+    if (MetadataPartitionType.fromPartitionPath(partitionName)
+          .equals(MetadataPartitionType.SECONDARY_INDEX)) {
+      // For secondary index, always use prefix matching

Review Comment:
   Sg



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