mkevo commented on pull request #7010: URL: https://github.com/apache/geode/pull/7010#issuecomment-963041221
The problem in failing tests is that with a fix, the limit added in the query will be applied only on results, not on index results. Size of indexResults is defined by INDEX_THRESHOLD_SIZE. A new test case(_testLimitIsAppliedOnlyOnQueryResults_ in QueryWithRangeIndexDUnitTest.java) is added to verify it. Not sure what to do with failing tests, as they have assertions to check if limitAppliedAtIndex, and it will not apply as it checks INDEX_THRESHOLD_SIZE for limit at index. Also, this can be fixed by the first proposal with fetching INDEX_THRESHOLD_SIZE every time the index is queried, but think that it is not the best solution as it will not take INDEX_THRESHOLD_SIZE into a count if it is not specified in the server startup command. This can lead to not collecting results in indexResults and the result of the query can be wrong. Also, the PR name should be something like: _GEODE-9632: Add option to apply INDEX_THRESHOLD_SIZE on index results_, as it will not overwrite RESULT_LIMIT for printing results, just for collection of index results. -- 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: notifications-unsubscr...@geode.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org