Skip to content

Commit de9e5f7

Browse files
committed
Test Fixes
1 parent 1d8b421 commit de9e5f7

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

exec/java-exec/src/test/java/org/apache/drill/exec/resourcemgr/RMBlobManagerTest.java

+7-1
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040
import org.apache.drill.test.ClusterFixture;
4141
import org.apache.drill.test.ClusterFixtureBuilder;
4242
import org.apache.drill.test.DrillTest;
43+
import org.junit.After;
4344
import org.junit.Before;
4445
import org.junit.Rule;
4546
import org.junit.Test;
@@ -156,9 +157,9 @@ public void testSetup() throws Exception {
156157
formemanQueueUsageValues);
157158

158159
final ClusterFixtureBuilder fixtureBuilder = ClusterFixture.builder(dirTestWatcher)
159-
.configProperty(ExecConstants.DRILL_PORT_HUNT, true)
160160
.configProperty(ExecConstants.RM_ENABLED, false)
161161
.setOptionDefault(ExecConstants.ENABLE_QUEUE.getOptionName(), false)
162+
.configProperty(ExecConstants.ALLOW_LOOPBACK_ADDRESS_BINDING, true)
162163
.withLocalZk();
163164

164165
// start the cluster
@@ -182,6 +183,11 @@ public void testSetup() throws Exception {
182183
rmConsistentBlobStoreManager.writeAllRMBlobs(blobsToSerialize);
183184
}
184185

186+
@After
187+
public void testCleanup() throws Exception {
188+
cluster.close();
189+
}
190+
185191
private void verifyBlobs() {
186192
// Again verify the updated blob value with initial value
187193
Iterator<Map.Entry<String, RMStateBlob>> blobs = rmConsistentBlobStoreManager.readAllRMBlobs();

exec/java-exec/src/test/java/org/apache/drill/exec/resourcemgr/TestDistributedQueryRM.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,7 @@ public class TestDistributedQueryRM extends ClusterTest {
6060

6161
@BeforeClass
6262
public static void setupTestSuite() throws Exception {
63-
final ClusterFixtureBuilder fixtureBuilder = ClusterFixture.builder(dirTestWatcher)
64-
.configProperty(ExecConstants.RM_ENABLED, true)
65-
.setOptionDefault(ExecConstants.ENABLE_QUEUE.getOptionName(), false)
66-
.configProperty(ExecConstants.DRILL_PORT_HUNT, true)
67-
.withLocalZk();
63+
final ClusterFixtureBuilder fixtureBuilder = ClusterFixture.builder(dirTestWatcher).configProperty(ExecConstants.RM_ENABLED, true).setOptionDefault(ExecConstants.ENABLE_QUEUE.getOptionName(), false).configProperty(ExecConstants.ALLOW_LOOPBACK_ADDRESS_BINDING, true).withLocalZk();
6864
startCluster(fixtureBuilder);
6965
context = cluster.drillbit().getContext();
7066
final ResourceManager rm = context.getResourceManager();

exec/java-exec/src/test/java/org/apache/drill/exec/resourcemgr/TestE2EWithDistributedRM.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ public class TestE2EWithDistributedRM extends ClusterTest {
3232
public static void setupTestSuite() throws Exception {
3333
final ClusterFixtureBuilder fixtureBuilder = ClusterFixture.builder(dirTestWatcher)
3434
.configProperty(ExecConstants.RM_ENABLED, true)
35-
.configProperty(ExecConstants.DRILL_PORT_HUNT, true)
3635
.setOptionDefault(ExecConstants.ENABLE_QUEUE.getOptionName(), false)
36+
.configProperty(ExecConstants.ALLOW_LOOPBACK_ADDRESS_BINDING, true)
3737
.withLocalZk();
3838
startCluster(fixtureBuilder);
3939
}

exec/java-exec/src/test/java/org/apache/drill/exec/resourcemgr/TestRMConfigLoad.java

+3-5
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,13 @@
3232
import org.apache.drill.test.ClusterFixture;
3333
import org.apache.drill.test.ClusterFixtureBuilder;
3434
import org.apache.drill.test.DrillTest;
35-
import org.junit.Ignore;
3635
import org.junit.Rule;
3736
import org.junit.Test;
3837
import org.junit.experimental.categories.Category;
3938

4039
import static org.junit.Assert.assertEquals;
4140
import static org.junit.Assert.assertTrue;
4241

43-
@Ignore("These tests will be ignored until integration with new DistributedResourceManager is done")
4442
@Category(ResourceManagerTest.class)
4543
public final class TestRMConfigLoad extends DrillTest {
4644

@@ -51,8 +49,8 @@ public final class TestRMConfigLoad extends DrillTest {
5149
public void testDefaultRMConfig() throws Exception {
5250
ClusterFixtureBuilder fixtureBuilder = ClusterFixture.builder(dirTestWatcher)
5351
.configProperty(ExecConstants.RM_ENABLED, true)
54-
.configProperty(ExecConstants.DRILL_PORT_HUNT, true)
5552
.setOptionDefault(ExecConstants.ENABLE_QUEUE.getOptionName(), false)
53+
.configProperty(ExecConstants.ALLOW_LOOPBACK_ADDRESS_BINDING, true)
5654
.withLocalZk();
5755

5856
try(ClusterFixture cluster = fixtureBuilder.build()) {
@@ -111,8 +109,8 @@ public void testDefaultRMWithLocalCoordinatorAndRMDisabled() throws Exception {
111109
public void testDefaultRMOnlyRMDisabled() throws Exception {
112110
ClusterFixtureBuilder fixtureBuilder = ClusterFixture.builder(dirTestWatcher)
113111
.configProperty(ExecConstants.RM_ENABLED, false)
114-
.configProperty(ExecConstants.DRILL_PORT_HUNT, true)
115112
.setOptionDefault(ExecConstants.ENABLE_QUEUE.getOptionName(), false)
113+
.configProperty(ExecConstants.ALLOW_LOOPBACK_ADDRESS_BINDING, true)
116114
.withLocalZk();
117115

118116
try (ClusterFixture cluster = fixtureBuilder.build()) {
@@ -126,8 +124,8 @@ public void testDefaultRMOnlyRMDisabled() throws Exception {
126124
public void testThrottleRMOnlyRMDisabled() throws Exception {
127125
ClusterFixtureBuilder fixtureBuilder = ClusterFixture.builder(dirTestWatcher)
128126
.configProperty(ExecConstants.RM_ENABLED, false)
129-
.configProperty(ExecConstants.DRILL_PORT_HUNT, true)
130127
.setOptionDefault(ExecConstants.ENABLE_QUEUE.getOptionName(), true)
128+
.configProperty(ExecConstants.ALLOW_LOOPBACK_ADDRESS_BINDING, true)
131129
.withLocalZk();
132130

133131
try (ClusterFixture cluster = fixtureBuilder.build()) {

0 commit comments

Comments
 (0)