lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a.@apache.org
Subject [43/58] [abbrv] lucene-solr:jira/solr-10879: SOLR-10979: Randomize PointFields in schema-docValues*.xml and all affected tests
Date Mon, 03 Jul 2017 11:58:23 GMT
SOLR-10979: Randomize PointFields in schema-docValues*.xml and all affected tests


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

Branch: refs/heads/jira/solr-10879
Commit: 0159d494f562a5a22c8e5ed7ad412fad62b5db55
Parents: b7fb61d
Author: Chris Hostetter <hossman@apache.org>
Authored: Thu Jun 29 15:09:39 2017 -0700
Committer: Chris Hostetter <hossman@apache.org>
Committed: Thu Jun 29 15:09:39 2017 -0700

----------------------------------------------------------------------
 solr/CHANGES.txt                                          |  1 +
 .../test-files/solr/collection1/conf/schema-docValues.xml | 10 +++++-----
 .../solr/collection1/conf/schema-docValuesFaceting.xml    | 10 +++++-----
 .../solr/collection1/conf/schema-docValuesJoin.xml        | 10 +++++-----
 .../solr/collection1/conf/schema-docValuesMissing.xml     | 10 +++++-----
 .../solr/collection1/conf/schema-docValuesMulti.xml       | 10 +++++-----
 .../test/org/apache/solr/schema/DocValuesMultiTest.java   | 10 +++++++---
 7 files changed, 33 insertions(+), 28 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/0159d494/solr/CHANGES.txt
----------------------------------------------------------------------
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index 30d334b..0d2226f 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -363,6 +363,7 @@ Other Changes
   - SOLR-10970: Randomize PointFields in all tests using schema-*sort* files (hossman)
   - SOLR-10971: Randomize PointFields in CdcrBootstrapTest (hossman)
   - SOLR-10977: Randomize the usage of Points based numerics in schema15.xml and all impacted
tests (hossman)
+  - SOLR-10979: Randomize PointFields in schema-docValues*.xml and all affected tests (hossman)
 
 * SOLR-6807: Changed requestDispatcher's handleSelect to default to false, thus ignoring
"qt".
   Simplified configs to not refer to handleSelect or "qt".  Switch all tests that assumed
true to assume false

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/0159d494/solr/core/src/test-files/solr/collection1/conf/schema-docValues.xml
----------------------------------------------------------------------
diff --git a/solr/core/src/test-files/solr/collection1/conf/schema-docValues.xml b/solr/core/src/test-files/solr/collection1/conf/schema-docValues.xml
index 0216791..4a5ab17 100644
--- a/solr/core/src/test-files/solr/collection1/conf/schema-docValues.xml
+++ b/solr/core/src/test-files/solr/collection1/conf/schema-docValues.xml
@@ -38,14 +38,14 @@
        These are provided more for backward compatability, allowing one
        to create a schema that matches an existing lucene index.
   -->
-  <fieldType name="int" class="solr.TrieIntField" precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
-  <fieldType name="float" class="solr.TrieFloatField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="long" class="solr.TrieLongField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="double" class="solr.TrieDoubleField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
+  <fieldType name="int" class="${solr.tests.IntegerFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="float" class="${solr.tests.FloatFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="long" class="${solr.tests.LongFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="double" class="${solr.tests.DoubleFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
   <!-- format for date is 1995-12-31T23:59:59.999Z and only the fractional
        seconds part (.999) is optional.
     -->
-  <fieldType name="date" class="solr.TrieDateField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
+  <fieldType name="date" class="${solr.tests.DateFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
 
   <fieldType name="boolean" class="solr.BoolField"/>
   <fieldType name="string" class="solr.StrField"/>

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/0159d494/solr/core/src/test-files/solr/collection1/conf/schema-docValuesFaceting.xml
----------------------------------------------------------------------
diff --git a/solr/core/src/test-files/solr/collection1/conf/schema-docValuesFaceting.xml b/solr/core/src/test-files/solr/collection1/conf/schema-docValuesFaceting.xml
index f7c6bfc..a8eed08 100644
--- a/solr/core/src/test-files/solr/collection1/conf/schema-docValuesFaceting.xml
+++ b/solr/core/src/test-files/solr/collection1/conf/schema-docValuesFaceting.xml
@@ -17,11 +17,11 @@
 -->
 
 <schema name="test" version="1.6">
-  <fieldType name="int" class="${solr.tests.IntegerFieldType}" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="float" class="${solr.tests.FloatFieldType}" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="long" class="${solr.tests.LongFieldType}" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="double" class="${solr.tests.DoubleFieldType}" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="date" class="${solr.tests.DateFieldType}" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
+  <fieldType name="int" class="${solr.tests.IntegerFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="float" class="${solr.tests.FloatFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="long" class="${solr.tests.LongFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="double" class="${solr.tests.DoubleFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="date" class="${solr.tests.DateFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
 
   <fieldType name="string" class="solr.StrField" sortMissingLast="true"/>
   <fieldType name="pint" class="solr.IntPointField"/>

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/0159d494/solr/core/src/test-files/solr/collection1/conf/schema-docValuesJoin.xml
----------------------------------------------------------------------
diff --git a/solr/core/src/test-files/solr/collection1/conf/schema-docValuesJoin.xml b/solr/core/src/test-files/solr/collection1/conf/schema-docValuesJoin.xml
index d2188fc..844a472 100644
--- a/solr/core/src/test-files/solr/collection1/conf/schema-docValuesJoin.xml
+++ b/solr/core/src/test-files/solr/collection1/conf/schema-docValuesJoin.xml
@@ -29,11 +29,11 @@
        1.5: omitNorms defaults to true for primitive field types (int, float, boolean, string...)
        1.6: useDocValuesAsStored defaults to true.
      -->
-  <fieldType name="int" class="solr.TrieIntField" precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
-  <fieldType name="float" class="solr.TrieFloatField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="long" class="solr.TrieLongField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="double" class="solr.TrieDoubleField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="date" class="solr.TrieDateField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
+  <fieldType name="int" class="${solr.tests.IntegerFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="float" class="${solr.tests.FloatFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="long" class="${solr.tests.LongFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="double" class="${solr.tests.DoubleFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="date" class="${solr.tests.DateFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
   <fieldtype name="string" class="solr.StrField" sortMissingLast="true" useDocValuesAsStored="false"/>
   <fieldType name="text" class="solr.TextField" positionIncrementGap="100" autoGeneratePhraseQueries="true">
     <analyzer type="index">

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/0159d494/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMissing.xml
----------------------------------------------------------------------
diff --git a/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMissing.xml b/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMissing.xml
index ac319e2..d80a426 100644
--- a/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMissing.xml
+++ b/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMissing.xml
@@ -19,11 +19,11 @@
 <!-- schema file for testing sorting/faceting/functions on single-valued DV with missing
values -->
 
 <schema name="schema-docValuesMissing" version="1.6">
-  <fieldType name="int" class="solr.TrieIntField" precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
-  <fieldType name="float" class="solr.TrieFloatField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="long" class="solr.TrieLongField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="double" class="solr.TrieDoubleField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="date" class="solr.TrieDateField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
+  <fieldType name="int" class="${solr.tests.IntegerFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="float" class="${solr.tests.FloatFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="long" class="${solr.tests.LongFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="double" class="${solr.tests.DoubleFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="date" class="${solr.tests.DateFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
   <fieldType name="string" class="solr.StrField"/>
   <fieldType name="boolean" class="solr.BoolField"/>
 

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/0159d494/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMulti.xml
----------------------------------------------------------------------
diff --git a/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMulti.xml b/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMulti.xml
index 81c7836..eb84189 100644
--- a/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMulti.xml
+++ b/solr/core/src/test-files/solr/collection1/conf/schema-docValuesMulti.xml
@@ -18,14 +18,14 @@
 
 <schema name="schema-docValuesMulti" version="1.6">
 
-  <fieldType name="int" class="solr.TrieIntField" precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
-  <fieldType name="float" class="solr.TrieFloatField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="long" class="solr.TrieLongField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
-  <fieldType name="double" class="solr.TrieDoubleField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
+  <fieldType name="int" class="${solr.tests.IntegerFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="float" class="${solr.tests.FloatFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="long" class="${solr.tests.LongFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
+  <fieldType name="double" class="${solr.tests.DoubleFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
   <!-- format for date is 1995-12-31T23:59:59.999Z and only the fractional
        seconds part (.999) is optional.
     -->
-  <fieldType name="date" class="solr.TrieDateField" precisionStep="0" omitNorms="true"
positionIncrementGap="0"/>
+  <fieldType name="date" class="${solr.tests.DateFieldType}" docValues="${solr.tests.numeric.dv}"
precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
 
   <fieldType name="boolean" class="solr.BoolField"/>
   <fieldType name="string" class="solr.StrField"/>

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/0159d494/solr/core/src/test/org/apache/solr/schema/DocValuesMultiTest.java
----------------------------------------------------------------------
diff --git a/solr/core/src/test/org/apache/solr/schema/DocValuesMultiTest.java b/solr/core/src/test/org/apache/solr/schema/DocValuesMultiTest.java
index 30dea85..8697b26 100644
--- a/solr/core/src/test/org/apache/solr/schema/DocValuesMultiTest.java
+++ b/solr/core/src/test/org/apache/solr/schema/DocValuesMultiTest.java
@@ -30,7 +30,7 @@ import org.junit.BeforeClass;
 import org.junit.Test;
 
 public class DocValuesMultiTest extends SolrTestCaseJ4 {
-
+  
   @BeforeClass
   public static void beforeTests() throws Exception {
     initCore("solrconfig-basic.xml", "schema-docValuesMulti.xml");
@@ -55,6 +55,10 @@ public class DocValuesMultiTest extends SolrTestCaseJ4 {
 
   @Test
   public void testDocValues() throws IOException {
+
+    final DocValuesType expectedNumericDvType = Boolean.getBoolean(NUMERIC_POINTS_SYSPROP)
?
+      DocValuesType.SORTED_NUMERIC : DocValuesType.SORTED_SET;
+    
     assertU(adoc("id", "1", "floatdv", "4.5", "intdv", "-1", "intdv", "3",
         "stringdv", "value1", "stringdv", "value2",
         "booldv", "false", "booldv", "true"));
@@ -68,8 +72,8 @@ public class DocValuesMultiTest extends SolrTestCaseJ4 {
         final FieldInfos infos = reader.getFieldInfos();
         assertEquals(DocValuesType.SORTED_SET, infos.fieldInfo("stringdv").getDocValuesType());
         assertEquals(DocValuesType.SORTED_SET, infos.fieldInfo("booldv").getDocValuesType());
-        assertEquals(DocValuesType.SORTED_SET, infos.fieldInfo("floatdv").getDocValuesType());
-        assertEquals(DocValuesType.SORTED_SET, infos.fieldInfo("intdv").getDocValuesType());
+        assertEquals(expectedNumericDvType, infos.fieldInfo("floatdv").getDocValuesType());
+        assertEquals(expectedNumericDvType, infos.fieldInfo("intdv").getDocValuesType());
 
         SortedSetDocValues dv = reader.getSortedSetDocValues("stringdv");
         assertEquals(0, dv.nextDoc());


Mime
View raw message