Github user romseygeek commented on the issue:
https://github.com/apache/lucene-solr/pull/345
bq. I agree that making the call fully lazy would be ideal
This can't be done, unfortunately, as we need to know up-front if there's a
match or not. Hence the slightly odd
Github user jpountz commented on the issue:
https://github.com/apache/lucene-solr/pull/345
> instead of directly returning the MatchesIterator
I asked for this change so that you always get a fresh new iterator, even
if you already iterated positions on the same field. I
Github user dsmiley commented on the issue:
https://github.com/apache/lucene-solr/pull/345
Curious; what led to the addition of the MatchesIteratorSupplier instead of
directly returning the MatchesIterator? Whatever your response may be, does
the eager call to `.get` in
Github user romseygeek commented on the issue:
https://github.com/apache/lucene-solr/pull/345
I extended MatchesAsserter to keep track of the last matching document, and
check that if the document one below the current collection is not a hit, then
its Matches is null.
---
Github user jpountz commented on the issue:
https://github.com/apache/lucene-solr/pull/345
Can we also check that it returns null on non-matching documents?
---
-
To unsubscribe, e-mail:
Github user romseygeek commented on the issue:
https://github.com/apache/lucene-solr/pull/345
I added an assertion to QueryUtils that calls Weight.matches() for each
collected document and ensures that the response isn't null (this actually
caught a bug in MTQ's handling). I've also
Github user romseygeek commented on the issue:
https://github.com/apache/lucene-solr/pull/345
> In term of testing, I think we should enforce some consistency with
extractTerms
The two aren't always consistent - for example, TermInSetQuery and
Github user romseygeek commented on the issue:
https://github.com/apache/lucene-solr/pull/345
> For instance I don't think it should try to report matches whenever there
are no terms involved
The reason I did this was to make Boolean matching accurate. Say for
example you