wombatu-kun commented on code in PR #18304:
URL: https://github.com/apache/hudi/pull/18304#discussion_r2952884568
##########
hudi-spark-datasource/hudi-spark/src/test/java/org/apache/hudi/io/storage/TestHoodieSparkLanceReader.java:
##########
@@ -623,7 +639,21 @@ public void testReadWithRequestedSchema() throws Exception
{
count++;
}
assertEquals(3, count, "Should read all 3 records");
+
+ assertBloomFilter(reader, HoodieDynamicBoundedBloomFilter.class,
"key0", "key2", 3);
}
}
}
+
+ private void assertBloomFilter(HoodieSparkLanceReader reader, Class<?>
clazz, String minKey, String maxKey, int keyCount) {
+ BloomFilter bloomFilter = reader.readBloomFilter();
+ assertInstanceOf(clazz, bloomFilter);
+ for (int i = 0; i < keyCount; i++) {
+ assertTrue(bloomFilter.mightContain("key" + (keyCount - 1)));
Review Comment:
Of course it should be `"key" + i`. It does not thow because `"key" +
(keyCount - 1)` is a valid key that bloom filter contains.
Fixed
--
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]