magibney commented on PR #2221:
URL: https://github.com/apache/solr/pull/2221#issuecomment-3514075692

   I wonder if it'd be possible to handle this all at the shard level. If the 
request is really constant-score, then in principle it should be possible to 
populate `maxScore` (and pseudo-`score` fields) by scoring just a single doc. 
This would address the backcompat concerns that @gus-asf raised.
   
   I came around to this thought because `rows=0` isn't the only case that it 
makes sense to optimize here. As David suggests, "explicitly set "fl" to 
something that does not include score" is indeed a workaround for the `rows=0` 
case -- but for sort by score alone (and MatchAllDocs or constant-score query) 
`rows > 0` can also skip sort and score evaluation (simply returning a DocList 
in index order), which would be _way_ faster than any "workaround" sort, for 
the `rows > 0` case.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to