shubhamsrkdev commented on code in PR #15295:
URL: https://github.com/apache/lucene/pull/15295#discussion_r2513897673


##########
lucene/core/src/java/org/apache/lucene/index/IndexWriter.java:
##########
@@ -5336,7 +5342,13 @@ public int length() {
       // this segment:
       boolean useCompoundFile;
       synchronized (this) { // Guard segmentInfos
-        useCompoundFile = mergePolicy.useCompoundFile(segmentInfos, 
merge.info, this);
+        useCompoundFile =
+            merge
+                .getMergeInfo()
+                .info
+                .getCodec()
+                .compoundFormat()
+                .useCompoundFile(mergePolicy.size(merge.info, this), 
mergePolicy);

Review Comment:
   Hmm, makes sense, I prefer accessing through methods, let me change this.



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