Skip to content

[test] Close the input stream in FileBasedBloomFilterTest - #10890

Open
skyyyy955 wants to merge 1 commit into
apache:masterfrom
skyyyy955:fix/close-bloom-test-stream-20261030
Open

skyyyy955 wants to merge 1 commit into
apache:masterfrom
skyyyy955:fix/close-bloom-test-stream-20261030

Conversation

@skyyyy955

Copy link
Copy Markdown
Contributor

Purpose

Close the local input stream owned by FileBasedBloomFilterTest.testProbe. FileBasedBloomFilter.close() invalidates its cached page but leaves the shared input open, so JUnit cannot delete the temporary file on Windows.

Manage the test input and cache manager with try-with-resources. Keep the existing filter.close() call and cache assertions inside that scope so manager cleanup cannot hide an invalidation failure. This changes one test file and adds no production behavior.

Tests

Ran the complete FileBasedBloomFilterTest on Windows / JDK 8u451 and Linux / JDK 8u441:

Environment Before After
Windows 7 passed, 1 temporary-directory cleanup error 8 passed
Linux 8 passed 8 passed

mvn -o -B -ntp -pl paimon-common -am -DwildcardSuites=none -DfailIfNoTests=false -Dtest=FileBasedBloomFilterTest test

Both final runs passed without fast-build. Linux also validates Checkstyle outside a target-suppressed source path. Full-project tests and official PR CI have not run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant