xiangfu0 commented on code in PR #19998:
URL: https://github.com/apache/pinot/pull/19998#discussion_r4429967943


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/indexsegment/immutable/ImmutableSegmentLoader.java:
##########
@@ -154,7 +163,9 @@ public static ImmutableSegment load(File indexDir, 
IndexLoadingConfig indexLoadi
     }
     SegmentDirectoryLoader segmentLoader =
         
SegmentDirectoryLoaderRegistry.getSegmentDirectoryLoader(indexLoadingConfig.getSegmentDirectoryLoader());
-    SegmentDirectory segmentDirectory = segmentLoader.load(indexDir.toURI(), 
segmentLoaderContext);
+    SegmentDirectory segmentDirectory = segmentLoader.load(indexDir.toURI(),
+        indexLoadingConfig.isMappedSegmentMetadataEnabled()
+            ? segmentLoaderContext.withMappedMetadataEnabled() : 
segmentLoaderContext);

Review Comment:
   Fixed in fdafe1c7e3. BaseTableDataManager now marks the directory loader 
context when mapped metadata is enabled, covering existing-segment startup and 
directory-reuse reload. The focused BaseTableDataManagerTest intercepts both 
server loader calls to verify the marked context, then checks mapped metadata 
and freshness after a canonical metadata change. The focused test and affected 
Spotless, Checkstyle, and license checks pass. The published PR head matches 
this commit.



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