SOLR-10064: The Nightly test HdfsCollectionsAPIDistributedZkTest appears to be too fragile.

This commit is contained in:
markrmiller 2017-02-17 11:03:08 -05:00
parent 33e398c021
commit 6b169d2051
2 changed files with 4 additions and 1 deletions

View File

@ -482,7 +482,7 @@ public class CollectionsAPIDistributedZkTest extends SolrCloudTestCase {
public void testCollectionsAPI() throws Exception {
// create new collections rapid fire
int cnt = random().nextInt(TEST_NIGHTLY ? 6 : 1) + 1;
int cnt = random().nextInt(TEST_NIGHTLY ? 3 : 1) + 1;
CollectionAdminRequest.Create[] createRequests = new CollectionAdminRequest.Create[cnt];
for (int i = 0; i < cnt; i++) {

View File

@ -38,6 +38,8 @@ public class HdfsCollectionsAPIDistributedZkTest extends CollectionsAPIDistribut
@BeforeClass
public static void setupClass() throws Exception {
System.setProperty("solr.hdfs.blockcache.blocksperbank", "512");
System.setProperty("tests.hdfs.numdatanodes", "1");
dfsCluster = HdfsTestUtil.setupClass(createTempDir().toFile().getAbsolutePath());
ZkConfigManager configManager = new ZkConfigManager(zkClient());
@ -53,6 +55,7 @@ public class HdfsCollectionsAPIDistributedZkTest extends CollectionsAPIDistribut
HdfsTestUtil.teardownClass(dfsCluster);
dfsCluster = null;
System.clearProperty("solr.hdfs.blockcache.blocksperbank");
System.clearProperty("tests.hdfs.numdatanodes");
System.clearProperty("solr.hdfs.home");
}