expani commented on code in PR #14511:
URL: https://github.com/apache/lucene/pull/14511#discussion_r2050377465


##########
lucene/core/src/java/org/apache/lucene/codecs/lucene103/Lucene103PostingsReader.java:
##########
@@ -282,6 +288,10 @@ public PostingsEnum postings(
   @Override
   public ImpactsEnum impacts(FieldInfo fieldInfo, BlockTermState state, int 
flags)
       throws IOException {
+    if (state.docFreq <= BLOCK_SIZE) {
+      // no skip data
+      return new SlowImpactsEnum(postings(fieldInfo, state, null, flags));
+    }

Review Comment:
   You understanding is spot on.
   
   The bug was this check getting extended to fields with `IndexOptions.DOCS`



##########
lucene/core/src/java/org/apache/lucene/codecs/lucene103/Lucene103PostingsReader.java:
##########
@@ -282,6 +288,10 @@ public PostingsEnum postings(
   @Override
   public ImpactsEnum impacts(FieldInfo fieldInfo, BlockTermState state, int 
flags)
       throws IOException {
+    if (state.docFreq <= BLOCK_SIZE) {
+      // no skip data
+      return new SlowImpactsEnum(postings(fieldInfo, state, null, flags));
+    }

Review Comment:
   Your understanding is spot on.
   
   The bug was this check getting extended to fields with `IndexOptions.DOCS`



-- 
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