You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by cp...@apache.org on 2017/02/24 21:20:03 UTC
[20/50] [abbrv] lucene-solr:jira/solr-6203: test: speed up test
test: speed up test
Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/a342d6bb
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/a342d6bb
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/a342d6bb
Branch: refs/heads/jira/solr-6203
Commit: a342d6bba6f5c3526763542ced8b4c7e5cda8d53
Parents: eb9e3cb
Author: markrmiller <ma...@apache.org>
Authored: Wed Feb 22 09:56:59 2017 -0500
Committer: markrmiller <ma...@apache.org>
Committed: Wed Feb 22 09:56:59 2017 -0500
----------------------------------------------------------------------
.../test/org/apache/solr/cloud/HttpPartitionTest.java | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/a342d6bb/solr/core/src/test/org/apache/solr/cloud/HttpPartitionTest.java
----------------------------------------------------------------------
diff --git a/solr/core/src/test/org/apache/solr/cloud/HttpPartitionTest.java b/solr/core/src/test/org/apache/solr/cloud/HttpPartitionTest.java
index 82fbec0..5ae4c17 100644
--- a/solr/core/src/test/org/apache/solr/cloud/HttpPartitionTest.java
+++ b/solr/core/src/test/org/apache/solr/cloud/HttpPartitionTest.java
@@ -71,7 +71,7 @@ public class HttpPartitionTest extends AbstractFullDistribZkTestBase {
// To prevent the test assertions firing too fast before cluster state
// recognizes (and propagates) partitions
- protected static final long sleepMsBeforeHealPartition = 2000L;
+ protected static final long sleepMsBeforeHealPartition = 300;
// give plenty of time for replicas to recover when running in slow Jenkins test envs
protected static final int maxWaitSecsToSeeAllActive = 90;
@@ -340,16 +340,16 @@ public class HttpPartitionTest extends AbstractFullDistribZkTestBase {
log.info("Looked up max version bucket seed "+maxVersionBefore+" for core "+coreName);
// now up the stakes and do more docs
- int numDocs = 1000;
+ int numDocs = TEST_NIGHTLY ? 1000 : 100;
boolean hasPartition = false;
for (int d = 0; d < numDocs; d++) {
// create / restore partition every 100 docs
- if (d % 100 == 0) {
+ if (d % 10 == 0) {
if (hasPartition) {
proxy.reopen();
hasPartition = false;
} else {
- if (d >= 100) {
+ if (d >= 10) {
proxy.close();
hasPartition = true;
Thread.sleep(sleepMsBeforeHealPartition);
@@ -674,9 +674,9 @@ public class HttpPartitionTest extends AbstractFullDistribZkTestBase {
if (!allReplicasUp) {
try {
- Thread.sleep(1000L);
+ Thread.sleep(200L);
} catch (Exception ignoreMe) {}
- waitMs += 1000L;
+ waitMs += 200L;
}
} // end while