rahulgoswami commented on code in PR #14607:
URL: https://github.com/apache/lucene/pull/14607#discussion_r2462616657
##########
lucene/core/src/java/org/apache/lucene/index/SegmentInfos.java:
##########
@@ -410,6 +398,85 @@ private static void parseSegmentInfos(
SegmentInfo info =
codec.segmentInfoFormat().read(directory, segName, segmentID,
IOContext.READONCE);
info.setCodec(codec);
+ Version segMinVersion = info.getMinVersion();
+ Version segmentVersion = info.getVersion();
+
+ if (!segmentVersion.onOrAfter(infos.minSegmentLuceneVersion)) {
Review Comment:
Interesting. I generally find the `!` to be more readable in a natural
language flow. Will follow Lucene's convention with `== false`.
--
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]