Hi Daniele,

This is the Lucene dev list, I'm redirecting your question to
[email protected].

On Fri, Dec 31, 2021 at 5:35 PM Daniele Antuzi <[email protected]> wrote:
>
> Hi,
> I was taking a look at the Solr searcher to see how the filterCache is used: 
> https://github.com/apache/solr/blob/c2db3a943e665cfb39e9ea53640be40cf2c09fbc/solr/core/src/java/org/apache/solr/search/SolrIndexSearcher.java#L1379-L1398
> Reading the code, it turned out that the filterCache is not used if the sort 
> contains the score or if we don't have any score specified (by default, it 
> sorts by score).
> As far as I know, the filterCache contains an unordered set of documents so 
> the sort must be calculated after the application of the filter query.
> Then, also the score should be computed after the filter query to have a 
> smaller set of documents.
> That being said, I don't understand why Solr does not use the filterCache if 
> the score is somehow involved in the sort.
> In theory, it can
>
> apply the filter query reducing the number of result
> computes the score
> sort the results
>
> Am I missing something?
>
> Happy new year,
> Daniele
>


-- 
Adrien

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to