zhangyue19921010 commented on code in PR #11355:
URL: https://github.com/apache/paimon/pull/11355#discussion_r4667190580


##########
paimon-flink/paimon-flink-common/src/main/java/org/apache/paimon/flink/lookup/FileStoreLookupFunction.java:
##########
@@ -343,6 +343,10 @@ public Collection<RowData> lookup(RowData keyRow) {
             if (partitionLoader == null) {
                 return lookupInternal(key);
             }
+            // An empty selection must not keep serving a previously loaded 
partition.
+            if (partitionLoader.partitions().isEmpty()) {
+                return Collections.emptyList();
+            }
             List<BinaryRow> partitions =

Review Comment:
   Fixed in 4976a0d: when the selection becomes empty, the refresher now clears 
its current partitions and drops async refreshes started before that, so 
lookups stay empty until a cache built after the empty selection is installed 
(the test now checks the first lookup after recreating `pt=1`).



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