Details
-
Improvement
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
None
-
None
-
Reviewed
Description
The test org.apache.hadoop.hbase.master.cleaner.TestReplicationHFileCleaner.testIsFileDeletable is not idempotent and fail if run twice in the same JVM, because it pollutes some states shared among tests. It may be good to clean this state pollution so that some other tests do not fail in the future due to the shared state polluted by this test.
Detail
Running TestReplicationHFileCleaner.testIsFileDeletable twice would result in the second run failing due to the following assertion error:
java.lang.AssertionError: Cleaner should allow to delete this file as there is no hfile reference node for it in the queue.
The root cause is that the a hfile reference is added during the first test run, which doesn't get removed upon test exits. Therefore, in the second test run , cleaner.isFileDeletable(fs.getFileStatus(file))) would return false, resulting in the assertion error.
Attachments
Attachments
Issue Links
- links to