You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by sa...@apache.org on 2016/06/08 18:44:58 UTC

[1/2] lucene-solr:branch_6x: SOLR-9107: When creating a randomized SSL test config, 100% effective odds of using SSL and/or client auth should never be trumped by chance.

Repository: lucene-solr
Updated Branches:
  refs/heads/branch_6_1 3a57beaa9 -> eebce4a40
  refs/heads/branch_6x e49561668 -> ded16f8f1


SOLR-9107: When creating a randomized SSL test config, 100% effective odds of using SSL and/or client auth should never be trumped by chance.


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/ded16f8f
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/ded16f8f
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/ded16f8f

Branch: refs/heads/branch_6x
Commit: ded16f8f182c6527df1ea15830d65815227aed25
Parents: e495616
Author: Steve Rowe <sa...@apache.org>
Authored: Wed Jun 8 14:39:01 2016 -0400
Committer: Steve Rowe <sa...@apache.org>
Committed: Wed Jun 8 14:43:19 2016 -0400

----------------------------------------------------------------------
 .../src/java/org/apache/solr/util/RandomizeSSL.java              | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/ded16f8f/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java
----------------------------------------------------------------------
diff --git a/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java b/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java
index e7336d8..2450dad 100644
--- a/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java
+++ b/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java
@@ -105,9 +105,9 @@ public @interface RandomizeSSL {
       // even if we know SSL is disabled, always consume the same amount of randomness
       // that way all other test behavior should be consistent even if a user adds/removes @SuppressSSL
       
-      final boolean useSSL = TestUtil.nextInt(LuceneTestCase.random(), 0, 1000) < 
+      final boolean useSSL = TestUtil.nextInt(LuceneTestCase.random(), 0, 999) <
         (int)(1000 * getEffectiveOdds(ssl, LuceneTestCase.TEST_NIGHTLY, LuceneTestCase.RANDOM_MULTIPLIER));
-      final boolean useClientAuth = TestUtil.nextInt(LuceneTestCase.random(), 0, 1000) < 
+      final boolean useClientAuth = TestUtil.nextInt(LuceneTestCase.random(), 0, 999) <
         (int)(1000 * getEffectiveOdds(clientAuth, LuceneTestCase.TEST_NIGHTLY, LuceneTestCase.RANDOM_MULTIPLIER));
 
       return new SSLTestConfig(useSSL, useClientAuth);


[2/2] lucene-solr:branch_6_1: SOLR-9107: When creating a randomized SSL test config, 100% effective odds of using SSL and/or client auth should never be trumped by chance.

Posted by sa...@apache.org.
SOLR-9107: When creating a randomized SSL test config, 100% effective odds of using SSL and/or client auth should never be trumped by chance.


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/eebce4a4
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/eebce4a4
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/eebce4a4

Branch: refs/heads/branch_6_1
Commit: eebce4a406716c1e1f31dd77a8d184d6e910df96
Parents: 3a57bea
Author: Steve Rowe <sa...@apache.org>
Authored: Wed Jun 8 14:39:01 2016 -0400
Committer: Steve Rowe <sa...@apache.org>
Committed: Wed Jun 8 14:43:40 2016 -0400

----------------------------------------------------------------------
 .../src/java/org/apache/solr/util/RandomizeSSL.java              | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/eebce4a4/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java
----------------------------------------------------------------------
diff --git a/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java b/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java
index e7336d8..2450dad 100644
--- a/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java
+++ b/solr/test-framework/src/java/org/apache/solr/util/RandomizeSSL.java
@@ -105,9 +105,9 @@ public @interface RandomizeSSL {
       // even if we know SSL is disabled, always consume the same amount of randomness
       // that way all other test behavior should be consistent even if a user adds/removes @SuppressSSL
       
-      final boolean useSSL = TestUtil.nextInt(LuceneTestCase.random(), 0, 1000) < 
+      final boolean useSSL = TestUtil.nextInt(LuceneTestCase.random(), 0, 999) <
         (int)(1000 * getEffectiveOdds(ssl, LuceneTestCase.TEST_NIGHTLY, LuceneTestCase.RANDOM_MULTIPLIER));
-      final boolean useClientAuth = TestUtil.nextInt(LuceneTestCase.random(), 0, 1000) < 
+      final boolean useClientAuth = TestUtil.nextInt(LuceneTestCase.random(), 0, 999) <
         (int)(1000 * getEffectiveOdds(clientAuth, LuceneTestCase.TEST_NIGHTLY, LuceneTestCase.RANDOM_MULTIPLIER));
 
       return new SSLTestConfig(useSSL, useClientAuth);