Skip to content

HBASE-30095 Remove duplicate MiniDFSCluster startup in TestZooKeeper - #8556

Open
Sigma-Ma wants to merge 1 commit into
apache:masterfrom
Sigma-Ma:HBASE-30095-remove-duplicate-minidfs-start
Open

HBASE-30095 Remove duplicate MiniDFSCluster startup in TestZooKeeper#8556
Sigma-Ma wants to merge 1 commit into
apache:masterfrom
Sigma-Ma:HBASE-30095-remove-duplicate-minidfs-start

Conversation

@Sigma-Ma

Copy link
Copy Markdown
Contributor

JIRA: https://issues.apache.org/jira/browse/HBASE-30095

What changes were proposed in this pull request?

Remove the duplicate TEST_UTIL.startMiniDFSCluster(2) call from TestZooKeeper#setUpBeforeClass.

The first MiniDFSCluster startup is retained, preserving the intended test initialization sequence: start MiniDFSCluster, start MiniZooKeeper, configure the test environment, and then start MiniHBaseCluster for each test.

Why are the changes needed?

HBaseTestingUtil should manage only one MiniDFSCluster at a time. Calling startMiniDFSCluster twice replaces the stored dfsCluster and dfsClusterFixer references without shutting down the first cluster.

This can leave the first cluster running against the same test directories and cause HDFS namespace conflicts, including InconsistentFSStateException, in CI runs.

How was this patch tested?

mvn -pl hbase-server -am -Dtest=TestZooKeeper -Dsurefire.rerunFailingTestsCount=0 test

@Umeshkumar9414

Copy link
Copy Markdown
Contributor

This was intentionally added by @saintstack here 7df9490. Although I didn't get it, he can help us here.

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.

2 participants