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 2018/09/11 17:32:04 UTC

[7/7] lucene-solr:master: LUCENE-8343: change suggesters to use Long instead of long weight during indexing, and double instead of long score at suggest time

LUCENE-8343: change suggesters to use Long instead of long weight during indexing, and double instead of long score at suggest time


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

Branch: refs/heads/master
Commit: 398074d0f878d4ba262245e35fa1ea285e52b791
Parents: a619038 1a83a14
Author: Mike McCandless <mi...@apache.org>
Authored: Tue Sep 11 12:03:40 2018 -0400
Committer: Mike McCandless <mi...@apache.org>
Committed: Tue Sep 11 12:03:40 2018 -0400

----------------------------------------------------------------------
 lucene/MIGRATE.txt                              |  5 ++
 .../analyzing/BlendedInfixSuggester.java        |  7 +-
 .../analyzing/BlendedInfixSuggesterTest.java    | 73 +++++++++++++++-----
 solr/solr-ref-guide/src/suggester.adoc          |  8 ++-
 4 files changed, 73 insertions(+), 20 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/398074d0/lucene/MIGRATE.txt
----------------------------------------------------------------------
diff --cc lucene/MIGRATE.txt
index 90ed4fc,8467d72..e0e70a3
--- a/lucene/MIGRATE.txt
+++ b/lucene/MIGRATE.txt
@@@ -76,45 -76,3 +76,50 @@@ separate query
  Thanks to other optimizations that were added to Lucene 8, this query will be
  able to efficiently select the top-scoring document without having to visit
  all matches.
 +
 +## TopFieldCollector always assumes fillFields=true ##
 +
 +Because filling sort values doesn't have a significant overhead, the fillFields
 +option has been removed from TopFieldCollector factory methods. Everything
 +behaves as if it was set to true.
 +
 +## TopFieldCollector no longer takes a trackDocScores option ##
 +
 +Computing scores at collection time is less efficient than running a second
 +request in order to only compute scores for documents that made it to the top
 +hits. As a consequence, the trackDocScores option has been removed and can be
 +replaced with the new TopFieldCollector#populateScores helper method.
 +
 +## IndexSearcher.search(After) may return lower bounds of the hit count and TopDocs.totalHits is no longer a long ##
 +
 +Lucene 8 received optimizations for collection of top-k matches by not visiting
 +all matches. However these optimizations won't help if all matches still need
 +to be visited in order to compute the total number of hits. As a consequence,
 +IndexSearcher's search and searchAfter methods were changed to only count hits
 +accurately up to 1,000, and Topdocs.totalHits was changed from a long to an
 +object that says whether the hit count is accurate or a lower bound of the
 +actual hit count.
 +
 +## RAMDirectory, RAMFile, RAMInputStream, RAMOutputStream are deprecated ##
 +
 +This RAM-based directory implementation is an old piece of code that uses inefficient
 +thread synchronization primitives and can be confused as "faster" than the NIO-based
 +MMapDirectory. It is deprecated and scheduled for removal in future versions of 
 +Lucene. (LUCENE-8467, LUCENE-8438)
 +
 +## LeafCollector.setScorer() now takes a Scorable rather than a Scorer ##
 +
 +Scorer has a number of methods that should never be called from Collectors, for example
 +those that advance the underlying iterators.  To hide these, LeafCollector.setScorer()
 +now takes a Scorable, an abstract class that Scorers can extend, with methods
 +docId() and score() (LUCENE-6228)
 +
 +## Scorers must have non-null Weights ##
 +
 +If a custom Scorer implementation does not have an associated Weight, it can probably
 +be replaced with a Scorable instead.
++
++## Suggesters now return Long instead of long for weight() during indexing, and double
++instead of long at suggest time ##
++
++Most code should just require recompilation, though possibly requiring some added casts.