sajjad-moradi commented on code in PR #9938:
URL: https://github.com/apache/pinot/pull/9938#discussion_r1042833356


##########
pinot-core/src/main/java/org/apache/pinot/core/data/manager/realtime/RealtimeTableDataManager.java:
##########
@@ -543,9 +544,13 @@ public void replaceLLSegment(String segmentName, 
IndexLoadingConfig indexLoading
     TableConfig tableConfig = 
ZKMetadataProvider.getTableConfig(_propertyStore, _tableNameWithType);
     Preconditions.checkState(tableConfig != null, "Failed to get table config 
for table: {}", _tableNameWithType);
     Schema schema = ZKMetadataProvider.getTableSchema(_propertyStore, 
tableConfig);
-    indexLoadingConfig.updateTableConfigAndSchema(tableConfig, schema);
+
+    // Construct a new indexLoadingConfig with the updated tableConfig and 
schema.
+    InstanceDataManagerConfig instanceDataManagerConfig = 
indexLoadingConfig.getInstanceDataManagerConfig();
+    IndexLoadingConfig newIndexLoadingConfig = new 
IndexLoadingConfig(instanceDataManagerConfig, tableConfig, schema);
+
     try {
-      addSegment(indexDir, indexLoadingConfig);
+      addSegment(indexDir, newIndexLoadingConfig);

Review Comment:
   Good catch!



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