[ https://issues.apache.org/jira/browse/OAK-8046?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16771675#comment-16771675 ]
Thomas Mueller commented on OAK-8046: ------------------------------------- Thanks [~catholicon]! Feedback: * LOG.debug was changed to LOG.info, was that intentional? LOG.info("Change in index version detected..." * I think the logic is a bit hard to maintain. hasRewound() needs to be called at the right moment, always after next(). If we change FulltextPathCursor some more, I think there is a risk that hasRewound() isn't always called at the right moment. A future change might be: add a skip method (to speed up queries with offset). I'm not saying we need to add this... but I think conceptually hasRewound is a bit tricky. * Maybe it would be simpler if the LuceneResultRowIterator would maintain the read count itself, and so instead of boolean hasRewound add a method getReadCount? So rename IteratorRewoundStateProvider to IteratorReadSizeProvider > Result items are not always correctly counted against the configured read > limit if a query uses a lucene index > --------------------------------------------------------------------------------------------------------------- > > Key: OAK-8046 > URL: https://issues.apache.org/jira/browse/OAK-8046 > Project: Jackrabbit Oak > Issue Type: Bug > Components: lucene > Affects Versions: 1.8.7 > Reporter: Georg Henzler > Assignee: Vikas Saurabh > Priority: Major > Attachments: OAK-8046.patch > > > There are cases where an index is re-opened during query execution. In that > case, already returned entries are read again and skipped, so basically > counted twice. This should be fixed to only count entries once (see also [1]) > The issue most likely exists since the read limit was introduced with OAK-6875 > [1] > https://lists.apache.org/thread.html/dddf9834fee0bccb6e48f61ba2a01430e34fc0b464b12809f7dfe2eb@%3Coak-dev.jackrabbit.apache.org%3E -- This message was sent by Atlassian JIRA (v7.6.3#76005)