haibow commented on a change in pull request #4954: Support schema evolution 
for consuming segments
URL: https://github.com/apache/incubator-pinot/pull/4954#discussion_r363924875
 
 

 ##########
 File path: 
pinot-server/src/main/java/org/apache/pinot/server/starter/helix/HelixInstanceDataManager.java
 ##########
 @@ -194,7 +198,17 @@ private void reloadSegment(String tableNameWithType, 
SegmentMetadata segmentMeta
 
     File indexDir = segmentMetadata.getIndexDir();
     if (indexDir == null) {
-      LOGGER.info("Skip reloading REALTIME consuming segment: {} in table: 
{}", segmentName, tableNameWithType);
+      if (!_instanceDataManagerConfig.shouldReloadConsumingSegment()) {
+        LOGGER.info("Skip reloading REALTIME consuming segment: {} in table: 
{}", segmentName, tableNameWithType);
+        return;
+      }
+      LOGGER.info("Try reloading REALTIME consuming segment: {} in table: {}", 
segmentName, tableNameWithType);
+      SegmentMetadataImpl segmentMetadataImpl = (SegmentMetadataImpl) 
segmentMetadata;
 
 Review comment:
   Could you elaborate on what you mean? To me, this method is the 
implementation of `reload` API (i.e. "how it should do it"). The logics below 
indicate how immutable segments are reloaded. Here it's a bit different for 
consuming segments - we just compare the schema and update the newly added 
columns, without doing an actual segment reload/replace.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to