You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by mi...@apache.org on 2014/11/27 21:41:07 UTC

svn commit: r1642229 [4/7] - in /lucene/dev/branches/lucene6005: ./ dev-tools/ dev-tools/eclipse/dot.settings/ dev-tools/idea/lucene/benchmark/src/ dev-tools/idea/lucene/highlighter/ dev-tools/maven/ dev-tools/scripts/ lucene/ lucene/analysis/ lucene/a...

Modified: lucene/dev/branches/lucene6005/lucene/grouping/src/test/org/apache/lucene/search/grouping/GroupingSearchTest.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/grouping/src/test/org/apache/lucene/search/grouping/GroupingSearchTest.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/grouping/src/test/org/apache/lucene/search/grouping/GroupingSearchTest.java (original)
+++ lucene/dev/branches/lucene6005/lucene/grouping/src/test/org/apache/lucene/search/grouping/GroupingSearchTest.java Thu Nov 27 20:41:01 2014
@@ -229,6 +229,7 @@ public class GroupingSearchTest extends 
         newIndexWriterConfig(new MockAnalyzer(random())).setMergePolicy(newLogMergePolicy()));
     Document doc = new Document();
     doc.add(newField("group", "foo", StringField.TYPE_NOT_STORED));
+    doc.add(new SortedDocValuesField("group", new BytesRef("foo")));
     w.addDocument(doc);
 
     IndexSearcher indexSearcher = newSearcher(w.getReader());

Modified: lucene/dev/branches/lucene6005/lucene/grouping/src/test/org/apache/lucene/search/grouping/TestGrouping.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/grouping/src/test/org/apache/lucene/search/grouping/TestGrouping.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/grouping/src/test/org/apache/lucene/search/grouping/TestGrouping.java (original)
+++ lucene/dev/branches/lucene6005/lucene/grouping/src/test/org/apache/lucene/search/grouping/TestGrouping.java Thu Nov 27 20:41:01 2014
@@ -315,7 +315,9 @@ public class TestGrouping extends Lucene
         BytesRef groupValue = mvalGd.groupValue.exists() ? ((MutableValueStr) mvalGd.groupValue).value.get() : null;
         groups.add(new GroupDocs<>(Float.NaN, mvalGd.maxScore, mvalGd.totalHits, mvalGd.scoreDocs, groupValue, mvalGd.groupSortValues));
       }
-      return new TopGroups<>(mvalTopGroups.groupSort, mvalTopGroups.withinGroupSort, mvalTopGroups.totalHitCount, mvalTopGroups.totalGroupedHitCount, groups.toArray(new GroupDocs[groups.size()]), Float.NaN);
+      // NOTE: currenlty using diamond operator on MergedIterator (without explicit Term class) causes
+      // errors on Eclipse Compiler (ecj) used for javadoc lint
+      return new TopGroups<BytesRef>(mvalTopGroups.groupSort, mvalTopGroups.withinGroupSort, mvalTopGroups.totalHitCount, mvalTopGroups.totalGroupedHitCount, groups.toArray(new GroupDocs[groups.size()]), Float.NaN);
     }
     fail();
     return null;

Modified: lucene/dev/branches/lucene6005/lucene/ivy-versions.properties
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/ivy-versions.properties?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/ivy-versions.properties (original)
+++ lucene/dev/branches/lucene6005/lucene/ivy-versions.properties Thu Nov 27 20:41:01 2014
@@ -79,7 +79,7 @@ com.sun.jersey.version = 1.9
 /mecab/mecab-ipadic = 2.7.0-20070801
 /mecab/mecab-naist-jdic = 0.6.3b-20111013
 /net.arnx/jsonic = 1.2.7
-/net.sf.saxon/Saxon-HE = 9.5.1-4
+/net.sf.saxon/Saxon-HE = 9.6.0-2
 /net.sourceforge.argparse4j/argparse4j = 0.4.3
 /net.sourceforge.jmatio/jmatio = 1.0
 /net.sourceforge.nekohtml/nekohtml = 1.9.17

Modified: lucene/dev/branches/lucene6005/lucene/join/src/test/org/apache/lucene/search/join/TestBlockJoin.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/join/src/test/org/apache/lucene/search/join/TestBlockJoin.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/join/src/test/org/apache/lucene/search/join/TestBlockJoin.java (original)
+++ lucene/dev/branches/lucene6005/lucene/join/src/test/org/apache/lucene/search/join/TestBlockJoin.java Thu Nov 27 20:41:01 2014
@@ -1295,6 +1295,7 @@ public class TestBlockJoin extends Lucen
     RandomIndexWriter w = new RandomIndexWriter(random(), d);
     Document parent = new Document();
     parent.add(new StoredField("parentID", "0"));
+    parent.add(new SortedDocValuesField("parentID", new BytesRef("0")));
     parent.add(newTextField("parentText", "text", Field.Store.NO));
     parent.add(newStringField("isParent", "yes", Field.Store.NO));
 
@@ -1315,6 +1316,7 @@ public class TestBlockJoin extends Lucen
     parent.add(newTextField("parentText", "text", Field.Store.NO));
     parent.add(newStringField("isParent", "yes", Field.Store.NO));
     parent.add(new StoredField("parentID", "1"));
+    parent.add(new SortedDocValuesField("parentID", new BytesRef("1")));
 
     // parent last:
     docs.add(parent);
@@ -1359,6 +1361,7 @@ public class TestBlockJoin extends Lucen
     RandomIndexWriter w = new RandomIndexWriter(random(), d);
     Document parent = new Document();
     parent.add(new StoredField("parentID", "0"));
+    parent.add(new SortedDocValuesField("parentID", new BytesRef("0")));
     parent.add(newTextField("parentText", "text", Field.Store.NO));
     parent.add(newStringField("isParent", "yes", Field.Store.NO));
 
@@ -1379,6 +1382,8 @@ public class TestBlockJoin extends Lucen
     parent.add(newTextField("parentText", "text", Field.Store.NO));
     parent.add(newStringField("isParent", "yes", Field.Store.NO));
     parent.add(new StoredField("parentID", "1"));
+    parent.add(new SortedDocValuesField("parentID", new BytesRef("1")));
+    
 
     // parent last:
     docs.add(parent);

Modified: lucene/dev/branches/lucene6005/lucene/join/src/test/org/apache/lucene/search/join/TestJoinUtil.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/join/src/test/org/apache/lucene/search/join/TestJoinUtil.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/join/src/test/org/apache/lucene/search/join/TestJoinUtil.java (original)
+++ lucene/dev/branches/lucene6005/lucene/join/src/test/org/apache/lucene/search/join/TestJoinUtil.java Thu Nov 27 20:41:01 2014
@@ -238,12 +238,14 @@ public class TestJoinUtil extends Lucene
     doc.add(new TextField("description", "random text", Field.Store.NO));
     doc.add(new TextField("name", "name1", Field.Store.NO));
     doc.add(new TextField(idField, "7", Field.Store.NO));
+    doc.add(new SortedDocValuesField(idField, new BytesRef("7")));
     w.addDocument(doc);
 
     // 1
     doc = new Document();
     doc.add(new TextField("price", "10.0", Field.Store.NO));
     doc.add(new TextField(idField, "2", Field.Store.NO));
+    doc.add(new SortedDocValuesField(idField, new BytesRef("2")));
     doc.add(new TextField(toField, "7", Field.Store.NO));
     w.addDocument(doc);
 
@@ -251,6 +253,7 @@ public class TestJoinUtil extends Lucene
     doc = new Document();
     doc.add(new TextField("price", "20.0", Field.Store.NO));
     doc.add(new TextField(idField, "3", Field.Store.NO));
+    doc.add(new SortedDocValuesField(idField, new BytesRef("3")));
     doc.add(new TextField(toField, "7", Field.Store.NO));
     w.addDocument(doc);
 
@@ -266,6 +269,7 @@ public class TestJoinUtil extends Lucene
     doc = new Document();
     doc.add(new TextField("price", "10.0", Field.Store.NO));
     doc.add(new TextField(idField, "5", Field.Store.NO));
+    doc.add(new SortedDocValuesField(idField, new BytesRef("5")));
     doc.add(new TextField(toField, "0", Field.Store.NO));
     w.addDocument(doc);
 
@@ -273,6 +277,7 @@ public class TestJoinUtil extends Lucene
     doc = new Document();
     doc.add(new TextField("price", "20.0", Field.Store.NO));
     doc.add(new TextField(idField, "6", Field.Store.NO));
+    doc.add(new SortedDocValuesField(idField, new BytesRef("6")));
     doc.add(new TextField(toField, "0", Field.Store.NO));
     w.addDocument(doc);
 

Modified: lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/index/sorter/SortingLeafReader.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/index/sorter/SortingLeafReader.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/index/sorter/SortingLeafReader.java (original)
+++ lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/index/sorter/SortingLeafReader.java Thu Nov 27 20:41:01 2014
@@ -770,12 +770,7 @@ public class SortingLeafReader extends F
   
   @Override
   public Fields fields() throws IOException {
-    Fields fields = in.fields();
-    if (fields == null) {
-      return null;
-    } else {
-      return new SortingFields(fields, in.getFieldInfos(), docMap);
-    }
+    return new SortingFields(in.fields(), in.getFieldInfos(), docMap);
   }
   
   @Override

Modified: lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/misc/HighFreqTerms.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/misc/HighFreqTerms.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/misc/HighFreqTerms.java (original)
+++ lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/misc/HighFreqTerms.java Thu Nov 27 20:41:01 2014
@@ -96,19 +96,17 @@ public class HighFreqTerms {
     TermStatsQueue tiq = null;
     
     if (field != null) {
-      Fields fields = MultiFields.getFields(reader);
-      if (fields == null) {
+      Terms terms = MultiFields.getTerms(reader, field);
+      if (terms == null) {
         throw new RuntimeException("field " + field + " not found");
       }
-      Terms terms = fields.terms(field);
-      if (terms != null) {
-        TermsEnum termsEnum = terms.iterator(null);
-        tiq = new TermStatsQueue(numTerms, comparator);
-        tiq.fill(field, termsEnum);
-      }
+
+      TermsEnum termsEnum = terms.iterator(null);
+      tiq = new TermStatsQueue(numTerms, comparator);
+      tiq.fill(field, termsEnum);
     } else {
       Fields fields = MultiFields.getFields(reader);
-      if (fields == null) {
+      if (fields.size() == 0) {
         throw new RuntimeException("no fields found for this index");
       }
       tiq = new TermStatsQueue(numTerms, comparator);

Modified: lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/DocTermOrds.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/DocTermOrds.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/DocTermOrds.java (original)
+++ lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/DocTermOrds.java Thu Nov 27 20:41:01 2014
@@ -20,7 +20,6 @@ package org.apache.lucene.uninverting;
 import java.io.IOException;
 import java.util.ArrayList;
 import java.util.Arrays;
-import java.util.Collections;
 import java.util.List;
 
 import org.apache.lucene.codecs.PostingsFormat; // javadocs
@@ -29,7 +28,6 @@ import org.apache.lucene.index.DocValues
 import org.apache.lucene.index.DocsAndPositionsEnum;
 import org.apache.lucene.index.DocsEnum;
 import org.apache.lucene.index.FieldInfo;
-import org.apache.lucene.index.Fields;
 import org.apache.lucene.index.LeafReader;
 import org.apache.lucene.index.SortedSetDocValues;
 import org.apache.lucene.index.Terms;
@@ -183,11 +181,6 @@ public class DocTermOrds implements Acco
     return sz;
   }
 
-  @Override
-  public Iterable<? extends Accountable> getChildResources() {
-    return Collections.emptyList();
-  }
-
   /** Inverts all terms */
   public DocTermOrds(LeafReader reader, Bits liveDocs, String field) throws IOException {
     this(reader, liveDocs, field, null, Integer.MAX_VALUE);
@@ -240,11 +233,7 @@ public class DocTermOrds implements Acco
   public TermsEnum getOrdTermsEnum(LeafReader reader) throws IOException {
     if (indexedTermsArray == null) {
       //System.out.println("GET normal enum");
-      final Fields fields = reader.fields();
-      if (fields == null) {
-        return null;
-      }
-      final Terms terms = fields.terms(field);
+      final Terms terms = reader.terms(field);
       if (terms == null) {
         return null;
       } else {
@@ -295,12 +284,7 @@ public class DocTermOrds implements Acco
     final int[] lastTerm = new int[maxDoc];    // last term we saw for this document
     final byte[][] bytes = new byte[maxDoc][]; // list of term numbers for the doc (delta encoded vInts)
 
-    final Fields fields = reader.fields();
-    if (fields == null) {
-      // No terms
-      return;
-    }
-    final Terms terms = fields.terms(field);
+    final Terms terms = reader.terms(field);
     if (terms == null) {
       // No terms
       return;

Modified: lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/FieldCache.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/FieldCache.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/FieldCache.java (original)
+++ lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/FieldCache.java Thu Nov 27 20:41:01 2014
@@ -19,7 +19,6 @@ package org.apache.lucene.uninverting;
 
 import java.io.IOException;
 import java.io.PrintStream;
-import java.util.Collections;
 
 import org.apache.lucene.analysis.NumericTokenStream;
 import org.apache.lucene.document.Document2;
@@ -61,11 +60,6 @@ interface FieldCache {
       // don't call on the in-progress value, might make things angry.
       return RamUsageEstimator.NUM_BYTES_OBJECT_REF;
     }
-
-    @Override
-    public Iterable<? extends Accountable> getChildResources() {
-      return Collections.emptyList();
-    }
   }
 
   /**

Modified: lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/FieldCacheImpl.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/FieldCacheImpl.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/FieldCacheImpl.java (original)
+++ lucene/dev/branches/lucene6005/lucene/misc/src/java/org/apache/lucene/uninverting/FieldCacheImpl.java Thu Nov 27 20:41:01 2014
@@ -383,11 +383,6 @@ class FieldCacheImpl implements FieldCac
         return base + (bits.length() >>> 3);
       }
     }
-
-    @Override
-    public Iterable<? extends Accountable> getChildResources() {
-      return Collections.emptyList();
-    }
   }
 
   static final class DocsWithFieldCache extends Cache {
@@ -488,11 +483,6 @@ class FieldCacheImpl implements FieldCac
     public long ramBytesUsed() {
       return values.ramBytesUsed() + RamUsageEstimator.NUM_BYTES_OBJECT_REF + RamUsageEstimator.NUM_BYTES_LONG;
     }
-    
-    @Override
-    public Iterable<? extends Accountable> getChildResources() {
-      return Collections.emptyList();
-    }
   }
 
   static final class LongCache extends Cache {

Modified: lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/CommonTermsQuery.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/CommonTermsQuery.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/CommonTermsQuery.java (original)
+++ lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/CommonTermsQuery.java Thu Nov 27 20:41:01 2014
@@ -239,10 +239,6 @@ public class CommonTermsQuery extends Qu
     TermsEnum termsEnum = null;
     for (LeafReaderContext context : leaves) {
       final Fields fields = context.reader().fields();
-      if (fields == null) {
-        // reader has no fields
-        continue;
-      }
       for (int i = 0; i < queryTerms.length; i++) {
         Term term = queryTerms[i];
         TermContext termContext = contextArray[i];

Modified: lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/TermsFilter.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/TermsFilter.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/TermsFilter.java (original)
+++ lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/TermsFilter.java Thu Nov 27 20:41:01 2014
@@ -186,9 +186,6 @@ public final class TermsFilter extends F
     BitDocIdSet.Builder builder = new BitDocIdSet.Builder(reader.maxDoc());
     final Fields fields = reader.fields();
     final BytesRef spare = new BytesRef(this.termsBytes);
-    if (fields == null) {
-      return builder.build();
-    }
     Terms terms = null;
     TermsEnum termsEnum = null;
     DocsEnum docs = null;

Modified: lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/SumTotalTermFreqValueSource.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/SumTotalTermFreqValueSource.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/SumTotalTermFreqValueSource.java (original)
+++ lucene/dev/branches/lucene6005/lucene/queries/src/java/org/apache/lucene/queries/function/valuesource/SumTotalTermFreqValueSource.java Thu Nov 27 20:41:01 2014
@@ -60,9 +60,7 @@ public class SumTotalTermFreqValueSource
   public void createWeight(Map context, IndexSearcher searcher) throws IOException {
     long sumTotalTermFreq = 0;
     for (LeafReaderContext readerContext : searcher.getTopReaderContext().leaves()) {
-      Fields fields = readerContext.reader().fields();
-      if (fields == null) continue;
-      Terms terms = fields.terms(indexedField);
+      Terms terms = readerContext.reader().terms(indexedField);
       if (terms == null) continue;
       long v = terms.getSumTotalTermFreq();
       if (v == -1) {

Modified: lucene/dev/branches/lucene6005/lucene/queries/src/test/org/apache/lucene/queries/function/TestBoostedQuery.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/queries/src/test/org/apache/lucene/queries/function/TestBoostedQuery.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/queries/src/test/org/apache/lucene/queries/function/TestBoostedQuery.java (original)
+++ lucene/dev/branches/lucene6005/lucene/queries/src/test/org/apache/lucene/queries/function/TestBoostedQuery.java Thu Nov 27 20:41:01 2014
@@ -4,7 +4,7 @@ package org.apache.lucene.queries.functi
 import org.apache.lucene.analysis.MockAnalyzer;
 import org.apache.lucene.document.Document;
 import org.apache.lucene.document.Field;
-import org.apache.lucene.document.StringField;
+import org.apache.lucene.document.SortedDocValuesField;
 import org.apache.lucene.index.IndexReader;
 import org.apache.lucene.index.IndexWriterConfig;
 import org.apache.lucene.index.RandomIndexWriter;
@@ -18,6 +18,7 @@ import org.apache.lucene.search.Sort;
 import org.apache.lucene.search.SortField;
 import org.apache.lucene.search.TopDocs;
 import org.apache.lucene.store.Directory;
+import org.apache.lucene.util.BytesRef;
 import org.apache.lucene.util.LuceneTestCase;
 import org.junit.AfterClass;
 import org.junit.BeforeClass;
@@ -55,7 +56,7 @@ public class TestBoostedQuery extends Lu
     iwConfig.setMergePolicy(newLogMergePolicy());
     RandomIndexWriter iw = new RandomIndexWriter(random(), dir, iwConfig);
     Document document = new Document();
-    Field idField = new StringField("id", "", Field.Store.NO);
+    Field idField = new SortedDocValuesField("id", new BytesRef());
     document.add(idField);
     iw.addDocument(document);
     ir = iw.getReader();

Modified: lucene/dev/branches/lucene6005/lucene/queryparser/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/queryparser/build.xml?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/queryparser/build.xml (original)
+++ lucene/dev/branches/lucene6005/lucene/queryparser/build.xml Thu Nov 27 20:41:01 2014
@@ -142,7 +142,7 @@ import org.apache.lucene.queryparser.fle
 
   <target name="resolve-javacc" xmlns:ivy="antlib:org.apache.ivy.ant">
     <!-- setup a "fake" JavaCC distribution folder in ${build.dir} to make JavaCC ANT task happy: -->
-    <ivy:retrieve organisation="net.java.dev.javacc" module="javacc" revision="5.0"
+    <ivy:retrieve organisation="net.java.dev.javacc" module="javacc" revision="5.0" symlink="${ivy.symlink}"
       inline="true" conf="default" transitive="false" type="jar" sync="true"
       pattern="${build.dir}/javacc/bin/lib/[artifact].[ext]"/>
   </target>

Modified: lucene/dev/branches/lucene6005/lucene/replicator/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/replicator/build.xml?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/replicator/build.xml (original)
+++ lucene/dev/branches/lucene6005/lucene/replicator/build.xml Thu Nov 27 20:41:01 2014
@@ -32,7 +32,7 @@
 	<target name="resolve" depends="common.resolve">
 		<sequential>
 	    <!-- javax.servlet jar -->
-	    <ivy:retrieve conf="servlet" log="download-only" type="orbit"/>
+	    <ivy:retrieve conf="servlet" log="download-only" type="orbit" symlink="${ivy.symlink}"/>
 		</sequential>
 	</target>
 

Modified: lucene/dev/branches/lucene6005/lucene/sandbox/src/java/org/apache/lucene/codecs/idversion/IDVersionPostingsReader.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/sandbox/src/java/org/apache/lucene/codecs/idversion/IDVersionPostingsReader.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/sandbox/src/java/org/apache/lucene/codecs/idversion/IDVersionPostingsReader.java (original)
+++ lucene/dev/branches/lucene6005/lucene/sandbox/src/java/org/apache/lucene/codecs/idversion/IDVersionPostingsReader.java Thu Nov 27 20:41:01 2014
@@ -18,7 +18,6 @@ package org.apache.lucene.codecs.idversi
  */
 
 import java.io.IOException;
-import java.util.Collections;
 
 import org.apache.lucene.codecs.BlockTermState;
 import org.apache.lucene.codecs.CodecUtil;
@@ -29,7 +28,6 @@ import org.apache.lucene.index.FieldInfo
 import org.apache.lucene.index.SegmentReadState;
 import org.apache.lucene.store.DataInput;
 import org.apache.lucene.store.IndexInput;
-import org.apache.lucene.util.Accountable;
 import org.apache.lucene.util.Bits;
 
 final class IDVersionPostingsReader extends PostingsReaderBase {
@@ -98,11 +96,6 @@ final class IDVersionPostingsReader exte
   public long ramBytesUsed() {
     return 0;
   }
-  
-  @Override
-  public Iterable<? extends Accountable> getChildResources() {
-    return Collections.emptyList();
-  }
 
   @Override
   public void checkIntegrity() throws IOException {

Modified: lucene/dev/branches/lucene6005/lucene/spatial/src/test/org/apache/lucene/spatial/SpatialExample.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/spatial/src/test/org/apache/lucene/spatial/SpatialExample.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/spatial/src/test/org/apache/lucene/spatial/SpatialExample.java (original)
+++ lucene/dev/branches/lucene6005/lucene/spatial/src/test/org/apache/lucene/spatial/SpatialExample.java Thu Nov 27 20:41:01 2014
@@ -23,6 +23,7 @@ import org.apache.lucene.document.Docume
 import org.apache.lucene.document.Document;
 import org.apache.lucene.document.Field;
 import org.apache.lucene.document.FieldTypes;
+import org.apache.lucene.document.NumericDocValuesField;
 import org.apache.lucene.document.StoredField;
 import org.apache.lucene.index.DirectoryReader;
 import org.apache.lucene.index.IndexReader;

Modified: lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/DocumentDictionary.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/DocumentDictionary.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/DocumentDictionary.java (original)
+++ lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/DocumentDictionary.java Thu Nov 27 20:41:01 2014
@@ -16,8 +16,11 @@ package org.apache.lucene.search.suggest
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
+
 import java.io.IOException;
+import java.util.ArrayList;
 import java.util.HashSet;
+import java.util.List;
 import java.util.Set;
 
 import org.apache.lucene.document.Document2;
@@ -30,6 +33,8 @@ import org.apache.lucene.search.spell.Di
 import org.apache.lucene.util.Bits;
 import org.apache.lucene.util.BytesRef;
 
+
+
 /**
  * <p>
  * Dictionary with terms, weights, payload (optional) and contexts (optional)
@@ -115,6 +120,8 @@ public class DocumentDictionary implemen
     private BytesRef currentPayload = null;
     private Set<BytesRef> currentContexts;
     private final NumericDocValues weightValues;
+    List<IndexableField> currentDocFields = new ArrayList<>();
+    int nextFieldsPosition = 0;
 
     /**
      * Creates an iterator over term, weight and payload fields from the lucene
@@ -137,7 +144,24 @@ public class DocumentDictionary implemen
 
     @Override
     public BytesRef next() throws IOException {
-      while (currentDocId < docCount) {
+      while (true) {
+        if (nextFieldsPosition < currentDocFields.size()) {
+          // Still values left from the document
+          IndexableField fieldValue =  currentDocFields.get(nextFieldsPosition++);
+          if (fieldValue.binaryValue() != null) {
+            return fieldValue.binaryValue();
+          } else if (fieldValue.stringValue() != null) {
+            return new BytesRef(fieldValue.stringValue());
+          } else {
+            continue;
+          }
+        }
+
+        if (currentDocId == docCount) {
+          // Iterated over all the documents.
+          break;
+        }
+
         currentDocId++;
         if (liveDocs != null && !liveDocs.get(currentDocId)) { 
           continue;
@@ -145,33 +169,50 @@ public class DocumentDictionary implemen
 
         Document2 doc = reader.document(currentDocId, relevantFields);
 
-        BytesRef tempPayload = null;
-        BytesRef tempTerm = null;
         Set<BytesRef> tempContexts = new HashSet<>();
 
+        BytesRef tempPayload;
         if (hasPayloads) {
           IndexableField payload = doc.getField(payloadField);
-          if (payload == null || (payload.binaryValue() == null && payload.stringValue() == null)) {
+          if (payload == null) {
+            continue;
+          } else if (payload.binaryValue() != null) {
+            tempPayload =  payload.binaryValue();
+          } else if (payload.stringValue() != null) {
+            tempPayload = new BytesRef(payload.stringValue());
+          } else {
             continue;
           }
-          tempPayload = (payload.binaryValue() != null) ? payload.binaryValue() : new BytesRef(payload.stringValue());
+        } else {
+          tempPayload = null;
         }
 
         if (hasContexts) {
           for (IndexableField contextField : doc.getFields(contextsField)) {
-            if (contextField.binaryValue() == null && contextField.stringValue() == null) {
-              continue;
+            if (contextField.binaryValue() != null) {
+              tempContexts.add(contextField.binaryValue());
+            } else if (contextField.stringValue() != null) {
+              tempContexts.add(new BytesRef(contextField.stringValue()));
             } else {
-              tempContexts.add((contextField.binaryValue() != null) ? contextField.binaryValue() : new BytesRef(contextField.stringValue()));
+              continue;
             }
           }
         }
 
-        IndexableField fieldVal = doc.getField(field);
-        if (fieldVal == null || (fieldVal.binaryValue() == null && fieldVal.stringValue() == null)) {
+        currentDocFields = doc.getFields(field);
+        nextFieldsPosition = 0;
+        if (currentDocFields.size() == 0) { // no values in this document
+          continue;
+        }
+        IndexableField fieldValue = currentDocFields.get(nextFieldsPosition++);
+        BytesRef tempTerm;
+        if (fieldValue.binaryValue() != null) {
+          tempTerm = fieldValue.binaryValue();
+        } else if (fieldValue.stringValue() != null) {
+          tempTerm = new BytesRef(fieldValue.stringValue());
+        } else {
           continue;
         }
-        tempTerm = (fieldVal.stringValue() != null) ? new BytesRef(fieldVal.stringValue()) : fieldVal.binaryValue();
 
         currentPayload = tempPayload;
         currentContexts = tempContexts;
@@ -179,6 +220,7 @@ public class DocumentDictionary implemen
 
         return tempTerm;
       }
+
       return null;
     }
 

Modified: lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/Lookup.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/Lookup.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/Lookup.java (original)
+++ lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/Lookup.java Thu Nov 27 20:41:01 2014
@@ -30,7 +30,6 @@ import org.apache.lucene.store.DataOutpu
 import org.apache.lucene.store.InputStreamDataInput;
 import org.apache.lucene.store.OutputStreamDataOutput;
 import org.apache.lucene.util.Accountable;
-import org.apache.lucene.util.Accountables;
 import org.apache.lucene.util.BytesRef;
 import org.apache.lucene.util.IOUtils;
 import org.apache.lucene.util.PriorityQueue;
@@ -268,14 +267,4 @@ public abstract class Lookup implements 
    * @throws IOException when fatal IO error occurs.
    */
   public abstract boolean load(DataInput input) throws IOException;
-
-  /**
-   * Returns nested resources of this class. 
-   * The result should be a point-in-time snapshot (to avoid race conditions).
-   * @see Accountables
-   */
-  @Override
-  public Iterable<? extends Accountable> getChildResources() {
-    return null;
-  }
 }

Modified: lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/jaspell/JaspellTernarySearchTrie.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/jaspell/JaspellTernarySearchTrie.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/jaspell/JaspellTernarySearchTrie.java (original)
+++ lucene/dev/branches/lucene6005/lucene/suggest/src/java/org/apache/lucene/search/suggest/jaspell/JaspellTernarySearchTrie.java Thu Nov 27 20:41:01 2014
@@ -32,7 +32,6 @@ package org.apache.lucene.search.suggest
 import java.io.BufferedReader;
 import java.io.IOException;
 import java.nio.charset.StandardCharsets;
-import java.util.Collections;
 import java.nio.file.Files;
 import java.nio.file.Path;
 import java.util.List;
@@ -111,11 +110,6 @@ public class JaspellTernarySearchTrie im
       }
       return mem;
     }
-    
-    @Override
-    public Iterable<? extends Accountable> getChildResources() {
-      return Collections.emptyList();
-    }
   }
 
   /**
@@ -903,9 +897,4 @@ public class JaspellTernarySearchTrie im
     }
     return mem;
   }
-  
-  @Override
-  public Iterable<? extends Accountable> getChildResources() {
-    return Collections.emptyList();
-  }
 }

Modified: lucene/dev/branches/lucene6005/lucene/suggest/src/test/org/apache/lucene/search/suggest/DocumentDictionaryTest.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/suggest/src/test/org/apache/lucene/search/suggest/DocumentDictionaryTest.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/suggest/src/test/org/apache/lucene/search/suggest/DocumentDictionaryTest.java (original)
+++ lucene/dev/branches/lucene6005/lucene/suggest/src/test/org/apache/lucene/search/suggest/DocumentDictionaryTest.java Thu Nov 27 20:41:01 2014
@@ -5,6 +5,7 @@ import java.util.AbstractMap.SimpleEntry
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.HashSet;
+import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 import java.util.Random;
@@ -298,4 +299,89 @@ public class DocumentDictionaryTest exte
     ir.close();
     dir.close();
   }
+
+  @Test
+  public void testMultiValuedField() throws IOException {
+    Directory dir = newDirectory();
+    IndexWriterConfig iwc = newIndexWriterConfig(random(), new MockAnalyzer(random()));
+    iwc.setMergePolicy(newLogMergePolicy());
+    RandomIndexWriter writer = new RandomIndexWriter(random(), dir, iwc);
+
+    List<Suggestion> suggestions = indexMultiValuedDocuments(atLeast(1000), writer);
+    writer.commit();
+    writer.close();
+
+    IndexReader ir = DirectoryReader.open(dir);
+    Dictionary dictionary = new DocumentDictionary(ir, FIELD_NAME, WEIGHT_FIELD_NAME, PAYLOAD_FIELD_NAME, CONTEXT_FIELD_NAME);
+    InputIterator inputIterator = dictionary.getEntryIterator();
+    BytesRef f;
+    Iterator<Suggestion> suggestionsIter = suggestions.iterator();
+    while((f = inputIterator.next())!=null) {
+      Suggestion nextSuggestion = suggestionsIter.next();
+      assertTrue(f.equals(nextSuggestion.term));
+      long weight = nextSuggestion.weight;
+      assertEquals(inputIterator.weight(), (weight != -1) ? weight : 0);
+      assertTrue(inputIterator.payload().equals(nextSuggestion.payload));
+      assertTrue(inputIterator.contexts().equals(nextSuggestion.contexts));
+    }
+    assertFalse(suggestionsIter.hasNext());
+    ir.close();
+    dir.close();
+  }
+
+  private List<Suggestion> indexMultiValuedDocuments(int numDocs, RandomIndexWriter writer) throws IOException {
+    List<Suggestion> suggestionList = new ArrayList<>(numDocs);
+
+    for(int i=0; i<numDocs; i++) {
+      Document doc = new Document();
+      Field field;
+      BytesRef payloadValue;
+      Set<BytesRef> contextValues = new HashSet<>();
+      long numericValue = -1; //-1 for missing weight
+      BytesRef term;
+
+      payloadValue = new BytesRef("payload_" + i);
+      field = new StoredField(PAYLOAD_FIELD_NAME, payloadValue);
+      doc.add(field);
+
+      if (usually()) {
+        numericValue = 100 + i;
+        field = new NumericDocValuesField(WEIGHT_FIELD_NAME, numericValue);
+        doc.add(field);
+      }
+
+      int numContexts = atLeast(1);
+      for (int j=0; j<numContexts; j++) {
+        BytesRef contextValue = new BytesRef("context_" + i + "_" + j);
+        field = new StoredField(CONTEXT_FIELD_NAME, contextValue);
+        doc.add(field);
+        contextValues.add(contextValue);
+      }
+
+      int numSuggestions = atLeast(2);
+      for (int j=0; j<numSuggestions; j++) {
+        term = new BytesRef("field_" + i + "_" + j);
+        field = new StoredField(FIELD_NAME, term);
+        doc.add(field);
+
+        Suggestion suggestionValue = new Suggestion();
+        suggestionValue.payload = payloadValue;
+        suggestionValue.contexts = contextValues;
+        suggestionValue.weight = numericValue;
+        suggestionValue.term = term;
+        suggestionList.add(suggestionValue);
+      }
+      writer.addDocument(doc);
+    }
+    return suggestionList;
+  }
+
+  private class Suggestion {
+    private long weight;
+    private BytesRef payload;
+    private Set<BytesRef> contexts;
+    private BytesRef term;
+  }
+
+
 }

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/build.xml?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/build.xml (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/build.xml Thu Nov 27 20:41:01 2014
@@ -22,6 +22,11 @@
 
   <property name="build.dir" location="../build/test-framework"/>
 
+  <!-- file is part of the API -->
+  <property name="forbidden-base-excludes" value="
+    org/apache/lucene/mockfile/FilterPath.class
+  "/>
+
   <import file="../common-build.xml"/>
 
   <path id="classpath">

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/codecs/ramonly/RAMOnlyPostingsFormat.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/codecs/ramonly/RAMOnlyPostingsFormat.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/codecs/ramonly/RAMOnlyPostingsFormat.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/codecs/ramonly/RAMOnlyPostingsFormat.java Thu Nov 27 20:41:01 2014
@@ -129,11 +129,6 @@ public final class RAMOnlyPostingsFormat
     }
 
     @Override
-    public Iterable<? extends Accountable> getChildResources() {
-      return Collections.emptyList();
-    }
-
-    @Override
     public long size() {
       return termToDocs.size();
     }
@@ -195,11 +190,6 @@ public final class RAMOnlyPostingsFormat
       }
       return sizeInBytes;
     }
-
-    @Override
-    public Iterable<? extends Accountable> getChildResources() {
-      return Collections.emptyList();
-    }
   }
 
   static class RAMDoc implements Accountable {
@@ -228,11 +218,6 @@ public final class RAMOnlyPostingsFormat
       }
       return sizeInBytes;
     }
-    
-    @Override
-    public Iterable<? extends Accountable> getChildResources() {
-      return Collections.emptyList();
-    }
   }
 
   // Classes for writing to the postings state

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/AssertingLeafReader.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/AssertingLeafReader.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/AssertingLeafReader.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/AssertingLeafReader.java Thu Nov 27 20:41:01 2014
@@ -43,8 +43,7 @@ public class AssertingLeafReader extends
 
   @Override
   public Fields fields() throws IOException {
-    Fields fields = super.fields();
-    return fields == null ? null : new AssertingFields(fields);
+    return new AssertingFields(super.fields());
   }
   
   @Override

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseDocValuesFormatTestCase.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseDocValuesFormatTestCase.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseDocValuesFormatTestCase.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseDocValuesFormatTestCase.java Thu Nov 27 20:41:01 2014
@@ -2499,6 +2499,7 @@ public abstract class BaseDocValuesForma
   }
   
   /** Tests dv against stored fields with threads (all types + missing) */
+  @Slow
   public void testThreads2() throws Exception {
     assumeTrue("Codec does not support getDocsWithField", codecSupportsDocsWithField());
     assumeTrue("Codec does not support SORTED_SET", codecSupportsSortedSet());
@@ -2665,6 +2666,7 @@ public abstract class BaseDocValuesForma
     dir.close();
   }
   
+  @Slow
   public void testThreads3() throws Exception {
     assumeTrue("Codec does not support getDocsWithField", codecSupportsDocsWithField());
     assumeTrue("Codec does not support SORTED_SET", codecSupportsSortedSet());

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseIndexFileFormatTestCase.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseIndexFileFormatTestCase.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseIndexFileFormatTestCase.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseIndexFileFormatTestCase.java Thu Nov 27 20:41:01 2014
@@ -218,6 +218,7 @@ abstract class BaseIndexFileFormatTestCa
   }
 
   /** Test the accuracy of the ramBytesUsed estimations. */
+  @Slow
   public void testRamBytesUsed() throws IOException {
     if (Codec.getDefault() instanceof RandomCodec) {
       // this test relies on the fact that two segments will be written with

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseNormsFormatTestCase.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseNormsFormatTestCase.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseNormsFormatTestCase.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/BaseNormsFormatTestCase.java Thu Nov 27 20:41:01 2014
@@ -186,6 +186,30 @@ public abstract class BaseNormsFormatTes
   }
   
   public void testNCommon() throws Exception {
+    final Random r = random();
+    final int N = TestUtil.nextInt(r, 2, 15);
+    final long[] commonValues = new long[N];
+    for (int j = 0; j < N; ++j) {
+      commonValues[j] = TestUtil.nextLong(r, Byte.MIN_VALUE, Byte.MAX_VALUE);
+    }
+    final int numOtherValues = TestUtil.nextInt(r, 2, 256 - N);
+    final long[] otherValues = new long[numOtherValues];
+    for (int j = 0; j < numOtherValues; ++j) {
+      otherValues[j] = TestUtil.nextLong(r, Byte.MIN_VALUE, Byte.MAX_VALUE);
+    }
+    doTestNormsVersusStoredFields(new LongProducer() {
+      @Override
+      long next() {
+        return r.nextInt(100) == 0 ? otherValues[r.nextInt(numOtherValues - 1)] : commonValues[r.nextInt(N - 1)];
+      }
+    });
+  }
+  
+  /**
+   * a more thorough n-common that tests all low bpv
+   */
+  @Nightly
+  public void testNCommonBig() throws Exception {
     final int iterations = atLeast(1);
     final Random r = random();
     for (int i = 0; i < iterations; ++i) {

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/PerThreadPKLookup.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/PerThreadPKLookup.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/PerThreadPKLookup.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/PerThreadPKLookup.java Thu Nov 27 20:41:01 2014
@@ -60,17 +60,14 @@ public class PerThreadPKLookup {
     int numSegs = 0;
     boolean hasDeletions = false;
     for(int i=0;i<leaves.size();i++) {
-      Fields fields = leaves.get(i).reader().fields();
-      if (fields != null) {
-        Terms terms = fields.terms(idFieldName);
-        if (terms != null) {
-          termsEnums[numSegs] = terms.iterator(null);
-          assert termsEnums[numSegs] != null;
-          docBases[numSegs] = leaves.get(i).docBase;
-          liveDocs[numSegs] = leaves.get(i).reader().getLiveDocs();
-          hasDeletions |= leaves.get(i).reader().hasDeletions();
-          numSegs++;
-        }
+      Terms terms = leaves.get(i).reader().terms(idFieldName);
+      if (terms != null) {
+        termsEnums[numSegs] = terms.iterator(null);
+        assert termsEnums[numSegs] != null;
+        docBases[numSegs] = leaves.get(i).docBase;
+        liveDocs[numSegs] = leaves.get(i).reader().getLiveDocs();
+        hasDeletions |= leaves.get(i).reader().hasDeletions();
+        numSegs++;
       }
     }
     this.numSegs = numSegs;

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/ThreadedIndexingAndSearchingTestCase.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/ThreadedIndexingAndSearchingTestCase.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/ThreadedIndexingAndSearchingTestCase.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/index/ThreadedIndexingAndSearchingTestCase.java Thu Nov 27 20:41:01 2014
@@ -340,9 +340,6 @@ public abstract class ThreadedIndexingAn
                   if (s.getIndexReader().numDocs() > 0) {
                     smokeTestSearcher(s);
                     Fields fields = MultiFields.getFields(s.getIndexReader());
-                    if (fields == null) {
-                      continue;
-                    }
                     Terms terms = fields.terms("body");
                     if (terms == null) {
                       continue;
@@ -650,8 +647,8 @@ public abstract class ThreadedIndexingAn
 
   private int runQuery(IndexSearcher s, Query q) throws Exception {
     s.search(q, 10);
-    int hitCount = s.search(q, null, 10, new Sort(new SortField("title", SortField.Type.STRING))).totalHits;
-    final Sort dvSort = new Sort(new SortField("title", SortField.Type.STRING));
+    int hitCount = s.search(q, null, 10, new Sort(new SortField("titleDV", SortField.Type.STRING))).totalHits;
+    final Sort dvSort = new Sort(new SortField("titleDV", SortField.Type.STRING));
     int hitCount2 = s.search(q, null, 10, dvSort).totalHits;
     assertEquals(hitCount, hitCount2);
     return hitCount;

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/store/BaseDirectoryTestCase.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/store/BaseDirectoryTestCase.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/store/BaseDirectoryTestCase.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/store/BaseDirectoryTestCase.java Thu Nov 27 20:41:01 2014
@@ -406,7 +406,7 @@ public abstract class BaseDirectoryTestC
       
       @Override
       public void run() {
-        for (int i = 0; i < 3000; i++) {
+        for (int i = 0; i < 1000; i++) {
           String fileName = this.name + i;
           try {
             //System.out.println("create:" + fileName);

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/store/MockDirectoryWrapper.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/store/MockDirectoryWrapper.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/store/MockDirectoryWrapper.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/store/MockDirectoryWrapper.java Thu Nov 27 20:41:01 2014
@@ -127,7 +127,7 @@ public class MockDirectoryWrapper extend
     // not be reproducible from the original seed
     this.randomState = new Random(random.nextInt());
     this.throttledOutput = new ThrottledIndexOutput(ThrottledIndexOutput
-        .mBitsToBytes(40 + randomState.nextInt(10)), 5 + randomState.nextInt(5), null);
+        .mBitsToBytes(40 + randomState.nextInt(10)), 1 + randomState.nextInt(5), null);
     init();
   }
 
@@ -180,7 +180,7 @@ public class MockDirectoryWrapper extend
   public static enum Throttling {
     /** always emulate a slow hard disk. could be very slow! */
     ALWAYS,
-    /** sometimes (2% of the time) emulate a slow hard disk. */
+    /** sometimes (0.5% of the time) emulate a slow hard disk. */
     SOMETIMES,
     /** never throttle output */
     NEVER

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/LineFileDocs.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/LineFileDocs.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/LineFileDocs.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/LineFileDocs.java Thu Nov 27 20:41:01 2014
@@ -39,6 +39,7 @@ import org.apache.lucene.document.Docume
 import org.apache.lucene.document.Field;
 import org.apache.lucene.document.FieldType;
 import org.apache.lucene.document.FieldTypes;
+import org.apache.lucene.document.NumericDocValuesField;
 import org.apache.lucene.document.SortedDocValuesField;
 import org.apache.lucene.document.StringField;
 import org.apache.lucene.document.TextField;

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/LuceneTestCase.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/LuceneTestCase.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/LuceneTestCase.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/LuceneTestCase.java Thu Nov 27 20:41:01 2014
@@ -902,7 +902,16 @@ public abstract class LuceneTestCase ext
     } else if (rarely(r)) {
       int maxThreadCount = TestUtil.nextInt(r, 1, 4);
       int maxMergeCount = TestUtil.nextInt(r, maxThreadCount, maxThreadCount + 4);
-      ConcurrentMergeScheduler cms = new ConcurrentMergeScheduler();
+      ConcurrentMergeScheduler cms;
+      if (r.nextBoolean()) {
+        cms = new ConcurrentMergeScheduler();
+      } else {
+        cms = new ConcurrentMergeScheduler() {
+            @Override
+            protected synchronized void maybeStall() {
+            }
+          };
+      }
       cms.setMaxMergesAndThreads(maxMergeCount, maxThreadCount);
       c.setMergeScheduler(cms);
     }
@@ -1316,7 +1325,7 @@ public abstract class LuceneTestCase ext
     }
     
     if (rarely(random) && !bare) { 
-      final double maxMBPerSec = 10 + 5*(random.nextDouble()-0.5);
+      final double maxMBPerSec = TestUtil.nextInt(random, 20, 40);
       if (LuceneTestCase.VERBOSE) {
         System.out.println("LuceneTestCase: will rate limit output IndexOutput to " + maxMBPerSec + " MB/sec");
       }

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/TestRuleTemporaryFilesCleanup.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/TestRuleTemporaryFilesCleanup.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/TestRuleTemporaryFilesCleanup.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/TestRuleTemporaryFilesCleanup.java Thu Nov 27 20:41:01 2014
@@ -1,14 +1,22 @@
 package org.apache.lucene.util;
 
 import java.io.IOException;
+import java.net.URI;
+import java.nio.file.FileSystem;
+import java.nio.file.FileSystems;
 import java.nio.file.Files;
 import java.nio.file.Path;
-import java.nio.file.Paths;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
 import java.util.Locale;
+import java.util.Random;
 
+import org.apache.lucene.mockfile.DisableFsyncFS;
+import org.apache.lucene.mockfile.HandleLimitFS;
+import org.apache.lucene.mockfile.LeakFS;
+import org.apache.lucene.mockfile.VerboseFS;
+import org.apache.lucene.mockfile.WindowsFS;
 import org.apache.lucene.util.LuceneTestCase.SuppressTempFileChecks;
 
 import com.carrotsearch.randomizedtesting.RandomizedContext;
@@ -52,6 +60,11 @@ final class TestRuleTemporaryFilesCleanu
    * Per-test class temporary folder.
    */
   private Path tempDirBase;
+  
+  /**
+   * Per-test filesystem
+   */
+  private FileSystem fileSystem;
 
   /**
    * Suite failure marker.
@@ -90,11 +103,39 @@ final class TestRuleTemporaryFilesCleanu
     super.before();
 
     assert tempDirBase == null;
+    fileSystem = initializeFileSystem();
     javaTempDir = initializeJavaTempDir();
   }
+  
+  // os/config-independent limit for too many open files
+  // TODO: can we make this lower?
+  private static final int MAX_OPEN_FILES = 2048;
+  
+  private FileSystem initializeFileSystem() {
+    FileSystem fs = FileSystems.getDefault();
+    if (LuceneTestCase.VERBOSE) {
+      fs = new VerboseFS(fs, new TestRuleSetupAndRestoreClassEnv.ThreadNameFixingPrintStreamInfoStream(System.out)).getFileSystem(null);
+    }
+    Random random = RandomizedContext.current().getRandom();
+    // sometimes just use a bare filesystem
+    if (random.nextInt(10) > 0) {
+      fs = new DisableFsyncFS(fs).getFileSystem(null);
+      fs = new LeakFS(fs).getFileSystem(null);
+      fs = new HandleLimitFS(fs, MAX_OPEN_FILES).getFileSystem(null);
+      // windows is currently slow
+      if (random.nextInt(10) == 0) {
+        fs = new WindowsFS(fs).getFileSystem(null);
+      }
+    }
+    if (LuceneTestCase.VERBOSE) {
+      System.out.println("filesystem: " + fs.provider());
+    }
+    return fs.provider().getFileSystem(URI.create("file:///"));
+  }
 
   private Path initializeJavaTempDir() throws IOException {
-    Path javaTempDir = Paths.get(System.getProperty("tempDir", System.getProperty("java.io.tmpdir")));
+    Path javaTempDir = fileSystem.getPath(System.getProperty("tempDir", System.getProperty("java.io.tmpdir")));
+    
     Files.createDirectories(javaTempDir);
 
     assert Files.isDirectory(javaTempDir) &&
@@ -134,6 +175,9 @@ final class TestRuleTemporaryFilesCleanu
         }
         throw e;
       }
+      if (fileSystem != FileSystems.getDefault()) {
+        fileSystem.close();
+      }
     } else {
       if (tempDirBasePath != null) {
         System.err.println("NOTE: leaving temporary files on disk at: " + tempDirBasePath);
@@ -171,7 +215,7 @@ final class TestRuleTemporaryFilesCleanu
     }
     return tempDirBase;
   }
-
+  
   /**
    * @see LuceneTestCase#createTempDir()
    */

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/TestUtil.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/TestUtil.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/TestUtil.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/TestUtil.java Thu Nov 27 20:41:01 2014
@@ -17,6 +17,7 @@ package org.apache.lucene.util;
  * limitations under the License.
  */
 
+import java.io.BufferedInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.IOException;
 import java.io.InputStream;
@@ -25,6 +26,7 @@ import java.io.PrintStream;
 import java.math.BigDecimal;
 import java.math.BigInteger;
 import java.nio.CharBuffer;
+import java.nio.file.FileSystem;
 import java.nio.file.Files;
 import java.nio.file.Path;
 import java.util.Arrays;
@@ -77,14 +79,19 @@ import org.apache.lucene.index.SegmentRe
 import org.apache.lucene.index.Terms;
 import org.apache.lucene.index.TermsEnum;
 import org.apache.lucene.index.TieredMergePolicy;
+import org.apache.lucene.mockfile.FilterFileSystem;
+import org.apache.lucene.mockfile.WindowsFS;
 import org.apache.lucene.search.FieldDoc;
 import org.apache.lucene.search.FilteredQuery.FilterStrategy;
 import org.apache.lucene.search.FilteredQuery;
 import org.apache.lucene.search.ScoreDoc;
 import org.apache.lucene.search.TopDocs;
 import org.apache.lucene.store.Directory;
+import org.apache.lucene.store.FSDirectory;
+import org.apache.lucene.store.FilterDirectory;
 import org.apache.lucene.store.NoLockFactory;
 import org.junit.Assert;
+
 import com.carrotsearch.randomizedtesting.generators.RandomInts;
 import com.carrotsearch.randomizedtesting.generators.RandomPicks;
 
@@ -102,6 +109,7 @@ public final class TestUtil {
    * Closes the given InputStream after extracting! 
    */
   public static void unzip(InputStream in, Path destDir) throws IOException {
+    in = new BufferedInputStream(in);
     IOUtils.rm(destDir);
     Files.createDirectory(destDir);
 
@@ -1113,6 +1121,35 @@ public final class TestUtil {
       }
     }
   }
+
+  /** Returns true if this is an FSDirectory backed by {@link WindowsFS}. */
+  public static boolean isWindowsFS(Directory dir) {
+    // First unwrap directory to see if there is an FSDir:
+    while (true) {
+      if (dir instanceof FSDirectory) {
+        return isWindowsFS(((FSDirectory) dir).getDirectory());
+      } else if (dir instanceof FilterDirectory) {
+        dir = ((FilterDirectory) dir).getDelegate();
+      } else {
+        return false;
+      }
+    }
+  }
+
+  /** Returns true if this Path is backed by {@link WindowsFS}. */
+  public static boolean isWindowsFS(Path path) {
+    FileSystem fs = path.getFileSystem();
+    while (true) {
+      if (fs instanceof FilterFileSystem) {
+        if (((FilterFileSystem) fs).getParent() instanceof WindowsFS) {
+          return true;
+        }
+        fs = ((FilterFileSystem) fs).getDelegate();
+      } else {
+        return false;
+      }
+    }
+  }
   
   /** List of characters that match {@link Character#isWhitespace} */
   public static final char[] WHITESPACE_CHARACTERS = new char[] {

Modified: lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/ThrottledIndexOutput.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/ThrottledIndexOutput.java?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/ThrottledIndexOutput.java (original)
+++ lucene/dev/branches/lucene6005/lucene/test-framework/src/java/org/apache/lucene/util/ThrottledIndexOutput.java Thu Nov 27 20:41:01 2014
@@ -53,7 +53,7 @@ public class ThrottledIndexOutput extend
   }
 
   public static final int mBitsToBytes(int mbits) {
-    return mbits * 125000;
+    return mbits * 125000000;
   }
 
   public ThrottledIndexOutput(int bytesPerSecond, long flushDelayMillis,

Modified: lucene/dev/branches/lucene6005/lucene/tools/javadoc/ecj.javadocs.prefs
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/lucene/tools/javadoc/ecj.javadocs.prefs?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/lucene/tools/javadoc/ecj.javadocs.prefs (original)
+++ lucene/dev/branches/lucene6005/lucene/tools/javadoc/ecj.javadocs.prefs Thu Nov 27 20:41:01 2014
@@ -4,9 +4,9 @@ org.eclipse.jdt.core.compiler.annotation
 org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
 org.eclipse.jdt.core.compiler.annotation.nonnullisdefault=disabled
 org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
+org.eclipse.jdt.core.compiler.compliance=1.8
 org.eclipse.jdt.core.compiler.doc.comment.support=enabled
 org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=ignore
 org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
@@ -93,4 +93,4 @@ org.eclipse.jdt.core.compiler.problem.un
 org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=ignore
 org.eclipse.jdt.core.compiler.problem.unusedWarningToken=ignore
 org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=ignore
-org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.compiler.source=1.8

Modified: lucene/dev/branches/lucene6005/solr/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/solr/CHANGES.txt?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/solr/CHANGES.txt (original)
+++ lucene/dev/branches/lucene6005/solr/CHANGES.txt Thu Nov 27 20:41:01 2014
@@ -29,6 +29,11 @@ Velocity 1.7 and Velocity Tools 2.0
 Apache UIMA 2.3.1
 Apache ZooKeeper 3.4.6
 
+System Requirements
+----------------------
+* LUCENE-5950: Move to Java 8 as minimum Java version.
+  (Ryan Ernst, Uwe Schindler)
+
 Upgrading from Solr 5.x
 ----------------------
 
@@ -40,7 +45,6 @@ Detailed Change List
 Other Changes
 ----------------------
 
-* SOLR-4792: Stop shipping a .war. (Robert Muir)
 
 ==================  5.0.0 ==================
 
@@ -100,6 +104,12 @@ Upgrading from Solr 4.x
   in the "def()" function. Example: changing "fl=sum(fieldA,fieldB)" to 
   "fl=sum(def(fieldA,0.0),def(fieldB,0.0))".  See LUCENE-5961 for more details.
 
+* AdminHandlers is deprecated , /admin/* are implicitly defined, /get ,/replacation and
+   handlers are also implicitly registered (refer to SOLR-6792)
+
+* SolrCore.reload(ConfigSet coreConfig, SolrCore prev) was deprecated in 4.10.3 and
+  removed in 5.0. use SolrCore.reload(ConfigSet coreConfig). See SOLR-5864.
+
 Detailed Change List
 ----------------------
 
@@ -133,7 +143,7 @@ New Features
   (Timothy Potter)
 
 * SOLR-5473 : Split clusterstate.json per collection and watch states selectively
-              (Noble Paul, Mark Miller, shalin, Jessica Cheng Mallet, Timothy Potter, Ashum Gupta)
+  (Noble Paul, Mark Miller, shalin, Jessica Cheng Mallet, Timothy Potter, Anshum Gupta)
 
 * SOLR-5474 : Support for SOLR-5473 in SolrJ (Timothy Potter, Noble Paul, Mark Miller)
 
@@ -205,7 +215,7 @@ New Features
   facet.pivot which refers to a 'tag' local param in one or more stats.field params.
   (hossman, Vitaliy Zhovtyuk, Steve Molloy)
 
-SOLR-6533: Support editing common solrconfig.xml values (Noble Paul)
+* SOLR-6533: Support editing common solrconfig.xml values (Noble Paul)
 
 Bug Fixes
 ----------------------
@@ -291,6 +301,12 @@ Bug Fixes
 
 * SOLR-6738: Admin UI - Escape Data on Plugins-View (steffkes)
 
+* SOLR-3774: Solr adds RequestHandler SolrInfoMBeans twice to the JMX server.
+  (Tomás Fernández Löbbe, hossman, Mark Miller)
+
+* SOLR-6763: Shard leader elections should not persist across session expiry
+  (Alan Woodward, Mark Miller)
+
 Optimizations
 ----------------------
 
@@ -355,6 +371,9 @@ Other Changes
 
 * SOLR-6453: Stop throwing an error message from Overseer when node exits (Ramkumar Aiyengar, Noble Paul)
 
+* SOLR-6550: Provide simple mechanism for passing additional metadata / context about a server-side
+   SolrException back to the client-side (Timothy Potter)
+
 * SOLR-6249: Schema API changes return success before all cores are updated; client application
   can provide the optional updateTimeoutSecs parameter to cause the server handling the
   managed schema update to block until all replicas of the same collection have processed the
@@ -397,6 +416,35 @@ Other Changes
 
 * SOLR-6740: Admin UI - improve Files View (steffkes)
 
+* SOLR-6570: Run SolrZkClient session watch asynchronously. 
+ (Ramkumar Aiyengar via Mark Miller)
+ 
+* SOLR-6747: Add an optional caching option as a workaround for SOLR-6586.
+  (Mark Miller, Gregory Chanan)
+
+* SOLR-6459: Normalize logging of operations in Overseer and log current queue size.
+  (Ramkumar Aiyengar, shalin via Mark Miller)
+
+* SOLR-6754: ZkController.publish doesn't use the updateLastState parameter.
+  (shalin)
+
+* SOLR-6715: ZkSolrResourceLoader constructors accept a parameter called 'collection'
+  but it should be 'configName'. (shalin)
+
+* SOLR-6751: Exceptions thrown in the analysis chain in DirectUpdateHandler2
+  should return a BAD_REQUEST status (Alan Woodward)
+
+* SOLR-6792 : deprecate AdminHandlers, Clean up solrconfig.xml of
+  unnecessary plugin definitions, implicit registration of /replication,
+  /get and /admin/* handlers (Noble Paul)
+
+* SOLR-5864: Remove previous SolrCore as parameter on reload.
+  (Tomás Fernández Löbbe) 
+
+* SOLR-4792: Stop shipping a .war. (Robert Muir, Ramkumar Aiyengar, Mark Miller)
+
+* SOLR-6799: Update Saxon-HE to 9.6.0-2. (Mark Miller)
+
 ==================  4.10.3 ==================
 
 Bug Fixes
@@ -408,6 +456,15 @@ Bug Fixes
 
 * SOLR-6085: Suggester crashes when prefixToken is longer than surface form (janhoy)
 
+* SOLR-6323: ReRankingQParserPlugin cleaner paging and fix bug with fuzzy, range and other queries 
+  that need to be re-written. (Adair Kovac, Joel Bernstein)
+
+* SOLR-6684: Fix-up /export JSON. (Joel Bernstein)
+
+* SOLR-6781: BBoxField didn't support dynamic fields. (David Smiley)
+
+* SOLR-6784: BBoxField's 'score' mode should have been optional. (David Smiley)
+
 ==================  4.10.2 ==================
 
 Bug Fixes

Modified: lucene/dev/branches/lucene6005/solr/README.txt
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/solr/README.txt?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/solr/README.txt (original)
+++ lucene/dev/branches/lucene6005/solr/README.txt Thu Nov 27 20:41:01 2014
@@ -111,10 +111,10 @@ docs/index.html
 Instructions for Building Apache Solr from Source
 -------------------------------------------------
 
-1. Download the Java SE 7 JDK (Java Development Kit) or later from http://java.sun.com/
+1. Download the Java SE 8 JDK (Java Development Kit) or later from http://www.oracle.com/java/
    You will need the JDK installed, and the $JAVA_HOME/bin (Windows: %JAVA_HOME%\bin) 
    folder included on your command path. To test this, issue a "java -version" command 
-   from your shell (command prompt) and verify that the Java version is 1.7 or later.
+   from your shell (command prompt) and verify that the Java version is 1.8 or later.
 
 2. Download the Apache Ant binary distribution (1.8.2+) from 
    http://ant.apache.org/  You will need Ant installed and the $ANT_HOME/bin (Windows: 

Modified: lucene/dev/branches/lucene6005/solr/SYSTEM_REQUIREMENTS.txt
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/solr/SYSTEM_REQUIREMENTS.txt?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/solr/SYSTEM_REQUIREMENTS.txt (original)
+++ lucene/dev/branches/lucene6005/solr/SYSTEM_REQUIREMENTS.txt Thu Nov 27 20:41:01 2014
@@ -1,9 +1,6 @@
 # System Requirements 
 
-Apache Solr runs of Java 7 or greater, Java 8 is verified to be
-compatible and may bring some performance improvements. When using
-Oracle Java 7 or OpenJDK 7, be sure to not use the GA build 147 or
-update versions u40, u45 and u51! We recommend using u55 or later.
+Apache Solr runs of Java 8 or greater.
 
 It is also recommended to always use the latest update version of your
 Java VM, because bugs may affect Solr. An overview of known JVM bugs

Modified: lucene/dev/branches/lucene6005/solr/bin/solr
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene6005/solr/bin/solr?rev=1642229&r1=1642228&r2=1642229&view=diff
==============================================================================
--- lucene/dev/branches/lucene6005/solr/bin/solr (original)
+++ lucene/dev/branches/lucene6005/solr/bin/solr Thu Nov 27 20:41:01 2014
@@ -51,7 +51,7 @@ hasLsof=$(which lsof)
 stop_all=false
 
 # for now, we don't support running this script from cygwin due to problems
-# like not having lsof, ps waux, curl, and awkward directory handling
+# like not having lsof, ps auxww, curl, and awkward directory handling
 if [ "${THIS_OS:0:6}" == "CYGWIN" ]; then
   echo -e "This script does not support cygwin due to severe limitations and lack of adherence\nto BASH standards, such as lack of lsof, curl, and ps options.\n\nPlease use the native solr.cmd script on Windows!"
   exit 1
@@ -258,7 +258,7 @@ function solr_pid_by_port() {
   THE_PORT="$1"
   if [ -e "$SOLR_TIP/bin/solr-$THE_PORT.pid" ]; then
     PID=`cat $SOLR_TIP/bin/solr-$THE_PORT.pid`
-    CHECK_PID=`ps waux | awk '{print $2}' | grep $PID | sort -r | tr -d ' '`
+    CHECK_PID=`ps auxww | awk '{print $2}' | grep $PID | sort -r | tr -d ' '`
     if [ "$CHECK_PID" != "" ]; then
       local solrPID=$PID
     fi
@@ -269,7 +269,7 @@ function solr_pid_by_port() {
 # extract the value of the -Djetty.port parameter from a running Solr process 
 function jetty_port() {
   SOLR_PID="$1"
-  SOLR_PROC=`ps waux | grep $SOLR_PID | grep start.jar | grep jetty.port`      
+  SOLR_PROC=`ps auxww | grep $SOLR_PID | grep start.jar | grep jetty.port`      
   IFS=' ' read -a proc_args <<< "$SOLR_PROC"
   for arg in "${proc_args[@]}"
     do
@@ -316,10 +316,10 @@ function get_info() {
     done
   else
     # no pid files but check using ps just to be sure
-    numSolrs=`ps waux | grep java | grep start.jar | wc -l | sed -e 's/^[ \t]*//'`
+    numSolrs=`ps auxww | grep java | grep start.jar | wc -l | sed -e 's/^[ \t]*//'`
     if [ "$numSolrs" != "0" ]; then
       echo -e "\nFound $numSolrs Solr nodes: "
-      for ID in `ps waux | grep java | grep start.jar | awk '{print $2}' | sort -r`
+      for ID in `ps auxww | grep java | grep start.jar | awk '{print $2}' | sort -r`
         do
           port=`jetty_port "$ID"`
           if [ "$port" != "" ]; then
@@ -357,7 +357,7 @@ function stop_solr() {
     exit 0
   fi
 
-  CHECK_PID=`ps waux | awk '{print $2}' | grep $SOLR_PID | sort -r | tr -d ' '`
+  CHECK_PID=`ps auxww | awk '{print $2}' | grep $SOLR_PID | sort -r | tr -d ' '`
   if [ "$CHECK_PID" != "" ]; then
     echo -e "Solr process $SOLR_PID is still running; forcefully killing it now."
     kill -9 $SOLR_PID
@@ -366,7 +366,7 @@ function stop_solr() {
     sleep 1
   fi
 
-  CHECK_PID=`ps waux | awk '{print $2}' | grep $SOLR_PID | sort -r | tr -d ' '`
+  CHECK_PID=`ps auxww | awk '{print $2}' | grep $SOLR_PID | sort -r | tr -d ' '`
   if [ "$CHECK_PID" != "" ]; then
     echo "ERROR: Failed to kill previous Solr Java process $SOLR_PID ... script fails."
     exit 1
@@ -409,17 +409,17 @@ if [ "$SCRIPT_CMD" == "healthcheck" ]; t
       case $1 in
           -c|-collection)
               if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-                print_usage "$SCRIPT_CMD" "Expected collection name but found $2 instead!"
-                exit 1            
+                print_usage "$SCRIPT_CMD" "Collection name is required when using the $1 option!"
+                exit 1
               fi
               HEALTHCHECK_COLLECTION=$2
               shift 2
           ;;
           -z|-zkhost)          
               if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-                print_usage "$SCRIPT_CMD" "Expected a ZooKeeper connection string but found $2 instead!"
-                exit 1            
-              fi          
+                print_usage "$SCRIPT_CMD" "ZooKeepeer connection string is required when using the $1 option!"
+                exit 1
+              fi
               ZK_HOST="$2"
               shift 2
           ;;
@@ -473,7 +473,7 @@ if [[ "$SCRIPT_CMD" == "create_core" || 
       case $1 in
           -n|-name)
               if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-                print_usage "$SCRIPT_CMD" "Expected $CREATE_TYPE name but found $2 instead!"
+                print_usage "$SCRIPT_CMD" "$CREATE_TYPE name is required when using the $1 option!"
                 exit 1
               fi
               CREATE_NAME=$2
@@ -481,7 +481,7 @@ if [[ "$SCRIPT_CMD" == "create_core" || 
           ;;
           -c|-configset)
               if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-                print_usage "$SCRIPT_CMD" "Expected configset name but found $2 instead!"
+                print_usage "$SCRIPT_CMD" "Configset name is required when using the $1 option!"
                 exit 1
               fi
               CREATE_CONFIGSET="$2"
@@ -489,7 +489,7 @@ if [[ "$SCRIPT_CMD" == "create_core" || 
           ;;
           -shards)
               if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-                print_usage "$SCRIPT_CMD" "Expected shard count but found $2 instead!"
+                print_usage "$SCRIPT_CMD" "Shard count is required when using the $1 option!"
                 exit 1
               fi
               CREATE_NUM_SHARDS="$2"
@@ -497,12 +497,20 @@ if [[ "$SCRIPT_CMD" == "create_core" || 
           ;;
           -replicationFactor)
               if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-                print_usage "$SCRIPT_CMD" "Expected replication factor but found $2 instead!"
+                print_usage "$SCRIPT_CMD" "Replication factor is required when using the $1 option!"
                 exit 1
               fi
               CREATE_REPFACT="$2"
               shift 2
           ;;
+          -p|-port)
+              if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
+                print_usage "$SCRIPT_CMD" "Solr port is required when using the $1 option!"
+                exit 1
+              fi
+              CREATE_PORT="$2"
+              shift 2
+          ;;
           -help|-usage)
               print_usage "$SCRIPT_CMD"
               exit 0
@@ -533,41 +541,28 @@ if [[ "$SCRIPT_CMD" == "create_core" || 
     exit 1
   fi
 
-  for ID in `ps waux | grep java | grep start.jar | awk '{print $2}' | sort -r`
-    do
-      port=`jetty_port "$ID"`
-      if [ "$port" != "" ]; then
-        CREATE_PORT=$port
-        break
-      fi
-  done
-
   if [ "$CREATE_PORT" == "" ]; then
-    echo "Failed to determine the port of a local Solr instance, cannot create $CREATE_TYPE!"
-    exit 1
+    for ID in `ps auxww | grep java | grep start.jar | awk '{print $2}' | sort -r`
+      do
+        port=`jetty_port "$ID"`
+        if [ "$port" != "" ]; then
+          CREATE_PORT=$port
+          break
+        fi
+    done
   fi
 
-  STATUS_INFO=`run_tool status -solr http://localhost:$CREATE_PORT/solr | tr -d ' '`
-  IS_CLOUD=`echo $STATUS_INFO | grep $'"cloud":' | tr -d ' '`
-  if [ "$IS_CLOUD" != "" ]; then
-    if [ "$SCRIPT_CMD" == "create_core" ]; then
-      echo -e "\nERROR: Solr running on port $CREATE_PORT is running in SolrCloud mode, please use create_collection command instead.\n"
-      exit 1
-    fi
-  else
-    if [ "$SCRIPT_CMD" == "create_collection" ]; then
-      echo -e "\nERROR: Solr running on port $CREATE_PORT is running in standalone server mode, please use the create_core command instead\ncreate_collection can only be used when running in SolrCloud mode.\n"
-      exit 1
-    fi
+  if [ "$CREATE_PORT" == "" ]; then
+    echo "Failed to determine the port of a local Solr instance, cannot create $CREATE_TYPE $CREATE_NAME"
+    exit 1
   fi
 
   if [ "$SCRIPT_CMD" == "create_collection" ]; then
     run_tool create_collection -name $CREATE_NAME -shards $CREATE_NUM_SHARDS -replicationFactor $CREATE_REPFACT \
       -config $CREATE_CONFIGSET -configsetsDir $SOLR_TIP/server/solr/configsets -solrUrl http://localhost:$CREATE_PORT/solr
   else
-    CREATE_URL="http://localhost:$CREATE_PORT/solr/admin/cores?action=CREATE&name=$CREATE_NAME&configSet=$CREATE_CONFIGSET"
-    echo -e "Creating new core using command:\n$CREATE_URL\n"
-    run_tool api -get $CREATE_URL
+    run_tool create_core -name $CREATE_NAME -solrUrl http://localhost:$CREATE_PORT/solr \
+      -config $CREATE_CONFIGSET -configsetsDir $SOLR_TIP/server/solr/configsets
   fi
 
   exit $?
@@ -576,7 +571,7 @@ fi
 
 # verify the command given is supported
 if [ "$SCRIPT_CMD" != "stop" ] && [ "$SCRIPT_CMD" != "start" ] && [ "$SCRIPT_CMD" != "restart" ]; then
-  print_usage "" "$SCRIPT_CMD not supported!"
+  print_usage "" "$SCRIPT_CMD is not a valid command!"
   exit 1
 fi
 
@@ -593,8 +588,8 @@ if [ $# -gt 0 ]; then
         ;;
         -d|-dir)
             if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-              print_usage "$SCRIPT_CMD" "Expected directory but found $2 instead!"
-              exit 1            
+              print_usage "$SCRIPT_CMD" "Server directory is required when using the $1 option!"
+              exit 1
             fi
 
             # see if the arg value is relative to the tip vs full path
@@ -607,7 +602,7 @@ if [ $# -gt 0 ]; then
         ;;
         -s|-solr.home)
             if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-              print_usage "$SCRIPT_CMD" "Expected directory but found $2 instead!"
+              print_usage "$SCRIPT_CMD" "Solr home directory is required when using the $1 option!"
               exit 1
             fi
 
@@ -616,8 +611,8 @@ if [ $# -gt 0 ]; then
         ;;
         -e|-example)
             if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-              print_usage "$SCRIPT_CMD" "Expected example name but found $2 instead!"
-              exit 1            
+              print_usage "$SCRIPT_CMD" "Example name is required when using the $1 option!"
+              exit 1
             fi
             EXAMPLE="$2"
             shift 2
@@ -628,34 +623,33 @@ if [ $# -gt 0 ]; then
         ;;
         -h|-host)
             if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-              print_usage "$SCRIPT_CMD" "Expected hostname but found $2 instead!"
-              exit 1            
+              print_usage "$SCRIPT_CMD" "Hostname is required when using the $1 option!"
+              exit 1
             fi
             SOLR_HOST="$2"
             shift 2
         ;;
         -m|-memory)
             if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-              print_usage "$SCRIPT_CMD" "Expected memory setting but found $2 instead!"
-              exit 1            
-            fi            
+              print_usage "$SCRIPT_CMD" "Memory setting is required when using the $1 option!"
+              exit 1
+            fi
             SOLR_HEAP="$2"
             shift 2
         ;;
         -p|-port)
             if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-              print_usage "$SCRIPT_CMD" "Expected port number but found $2 instead!"
-              exit 1            
-            fi            
+              print_usage "$SCRIPT_CMD" "Port number is required when using the $1 option!"
+              exit 1
+            fi
             SOLR_PORT="$2"
             shift 2
         ;;
         -z|-zkhost)
             if [[ "$2" == "" || "${2:0:1}" == "-" ]]; then
-              print_usage "$SCRIPT_CMD" "Expected ZooKeeper connection string but found $2 instead!"
-              exit 1            
+              print_usage "$SCRIPT_CMD" "ZooKeeper connection string is required when using the $1 option!"
+              exit 1
             fi
-
             ZK_HOST="$2"
             shift 2
         ;;
@@ -689,7 +683,7 @@ if [ $# -gt 0 ]; then
         ;;
         *)
             if [ "$1" != "" ]; then            
-              print_usage "$SCRIPT_CMD" "Error parsing argument $1!"
+              print_usage "$SCRIPT_CMD" "$1 is not supported by this script"
               exit 1
             else
               break # out-of-args, stop looping
@@ -782,15 +776,32 @@ if [ "$EXAMPLE" != "" ]; then
                 done
               done
             fi       
-            
-            for (( s=0; s<$CLOUD_NUM_NODES; s++ ))
+
+            # first, clone the server directory (w/o pulling over existing cores)
+            if [ ! -d "$SOLR_TIP/node1" ]; then
+              echo "Cloning $DEFAULT_SERVER_DIR into $SOLR_TIP/node1"
+              mkdir -p $SOLR_TIP/node1
+              cp -r $DEFAULT_SERVER_DIR/contexts $SOLR_TIP/node1/
+              cp -r $DEFAULT_SERVER_DIR/etc $SOLR_TIP/node1/
+              cp -r $DEFAULT_SERVER_DIR/lib $SOLR_TIP/node1/
+              cp -r $DEFAULT_SERVER_DIR/resources $SOLR_TIP/node1/
+              cp -r $DEFAULT_SERVER_DIR/scripts $SOLR_TIP/node1/
+              cp -r $DEFAULT_SERVER_DIR/webapps $SOLR_TIP/node1/
+              cp $DEFAULT_SERVER_DIR/start.jar $SOLR_TIP/node1/
+              mkdir -p $SOLR_TIP/node1/solr-webapp
+              mkdir -p $SOLR_TIP/node1/solr
+              cp -r $DEFAULT_SERVER_DIR/solr/configsets $SOLR_TIP/node1/solr/
+              cp $DEFAULT_SERVER_DIR/solr/solr.xml $SOLR_TIP/node1/solr/
+              cp $DEFAULT_SERVER_DIR/solr/zoo.cfg $SOLR_TIP/node1/solr/
+            fi
+
+            for (( s=1; s<$CLOUD_NUM_NODES; s++ ))
             do
               ndx=$[$s+1]
               if [ ! -d "$SOLR_TIP/node$ndx" ]; then
-                echo "Cloning $DEFAULT_SERVER_DIR into $SOLR_TIP/node$ndx"                 
-                cp -r $DEFAULT_SERVER_DIR $SOLR_TIP/node$ndx
-                rm -rf $SOLR_TIP/node$ndx/solr/zoo_data
-              fi              
+                echo "Cloning $SOLR_TIP/node1 into $SOLR_TIP/node$ndx"
+                cp -r $SOLR_TIP/node1 $SOLR_TIP/node$ndx
+              fi
             done
             SOLR_MODE="solrcloud"
             SOLR_SERVER_DIR="$SOLR_TIP/node1"
@@ -861,7 +872,7 @@ if [[ "$SCRIPT_CMD" == "start" ]]; then
 
   if [ "$SOLR_PID" == "" ]; then
     # not found using the pid file ... but use ps to ensure not found
-    SOLR_PID=`ps waux | grep start.jar | grep $SOLR_PORT | grep -v grep | awk '{print $2}' | sort -r`
+    SOLR_PID=`ps auxww | grep start.jar | grep $SOLR_PORT | grep -v grep | awk '{print $2}' | sort -r`
   fi
 
   if [ "$SOLR_PID" != "" ]; then
@@ -875,7 +886,7 @@ else
   SOLR_PID=`solr_pid_by_port "$SOLR_PORT"`
   if [ "$SOLR_PID" == "" ]; then
     # not found using the pid file ... but use ps to ensure not found
-    SOLR_PID=`ps waux | grep start.jar | grep $SOLR_PORT | grep -v grep | awk '{print $2}' | sort -r`
+    SOLR_PID=`ps auxww | grep start.jar | grep $SOLR_PORT | grep -v grep | awk '{print $2}' | sort -r`
   fi
   if [ "$SOLR_PID" != "" ]; then
     stop_solr "$SOLR_SERVER_DIR" "$SOLR_PORT" "$STOP_KEY" "$SOLR_PID"
@@ -1071,14 +1082,14 @@ $SOLR_OPTS"
             exit;
           fi
         else
-          SOLR_PID=`ps waux | grep start.jar | grep $SOLR_PORT | grep -v grep | awk '{print $2}' | sort -r`
+          SOLR_PID=`ps auxww | grep start.jar | grep $SOLR_PORT | grep -v grep | awk '{print $2}' | sort -r`
           echo -e "\nStarted Solr server on port $SOLR_PORT (pid=$SOLR_PID). Happy searching!\n"
           exit;
         fi
       done) &
       spinner $!
     else
-      SOLR_PID=`ps waux | grep start.jar | grep $SOLR_PORT | grep -v grep | awk '{print $2}' | sort -r`
+      SOLR_PID=`ps auxww | grep start.jar | grep $SOLR_PORT | grep -v grep | awk '{print $2}' | sort -r`
       echo -e "\nStarted Solr server on port $SOLR_PORT (pid=$SOLR_PID). Happy searching!\n"
       exit;
     fi
@@ -1094,9 +1105,8 @@ if [ "$EXAMPLE" != "cloud" ]; then
       run_tool create_collection -name $EXAMPLE -shards 1 -replicationFactor 1 \
         -config $EXAMPLE_CONFIGSET -configsetsDir $SOLR_TIP/server/solr/configsets -solrUrl http://localhost:$SOLR_PORT/solr
     else
-      CREATE_URL="http://localhost:$SOLR_PORT/solr/admin/cores?action=CREATE&name=$EXAMPLE&configSet=$EXAMPLE_CONFIGSET"
-      echo -e "Creating new core using command:\n$CREATE_URL\n"
-      run_tool api -get $CREATE_URL
+      run_tool create_core -name $EXAMPLE -solrUrl http://localhost:$SOLR_PORT/solr \
+        -config $EXAMPLE_CONFIGSET -configsetsDir $SOLR_TIP/server/solr/configsets
     fi
 
     if [ "$EXAMPLE" == "techproducts" ]; then