sgup432 commented on PR #15998: URL: https://github.com/apache/lucene/pull/15998#issuecomment-4663905978
@epotyom >IIUC currently, ScorerSupplier#cost has no requirement that cost must be 0 only when there are no matching docs in the segment - but with this change it effectively becomes one? That seems risky. Yeah I think my understanding was probably wrong here. I thought cost being 0 means no matches for sure, while cost>0 is an estimate. So the current approach taken in this PR is not right. >There was a bug in TermQuery where ScorerSupplier was non-null even when the term wasn't present in the segment; https://github.com/apache/lucene/pull/15627 fixed this for the non-prefetch (hot index) path by making TermStates.get() return null directly instead of deferring to a lambda. I'm curious whether that covered your use case? It might though I haven't checked it deep enough, will do. Thanks for the pointers. -- 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]
