[ 
https://issues.apache.org/jira/browse/LUCENE-6371?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14560603#comment-14560603
 ] 

Alan Woodward commented on LUCENE-6371:
---------------------------------------

It's because of the way scoring works on Spans.  We build a span tree, calling 
.getSpans() on the various weights as we go down the hierarchy, but scoring is 
only done by the top level, so we only want to build a Similarity in the 
top-level weight.  And because the Similarity is built in the constructor, we 
need to collect all the terms and termcontexts of the various leaves before the 
Weight itself is built, so we can't just pass needsScores.

Ideally scoring would be done on the Spans themselves (making them even more 
like just a specialized Scorer), but that's a bigger change.

> Improve Spans payload collection
> --------------------------------
>
>                 Key: LUCENE-6371
>                 URL: https://issues.apache.org/jira/browse/LUCENE-6371
>             Project: Lucene - Core
>          Issue Type: Improvement
>            Reporter: Paul Elschot
>            Assignee: Alan Woodward
>            Priority: Minor
>             Fix For: Trunk, 5.3
>
>         Attachments: LUCENE-6371.patch, LUCENE-6371.patch, LUCENE-6371.patch, 
> LUCENE-6371.patch
>
>
> Spin off from LUCENE-6308, see the comments there from around 23 March 2015.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to