nsivabalan commented on code in PR #8684:
URL: https://github.com/apache/hudi/pull/8684#discussion_r1190732568


##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/metadata/HoodieBackedTableMetadataWriter.java:
##########
@@ -892,25 +917,24 @@ public void buildMetadataPartitions(HoodieEngineContext 
engineContext, List<Hood
       }
       partitionTypes.add(partitionType);
     });
-    // before initial commit update inflight indexes in table config
-    Set<String> inflightIndexes = 
getInflightMetadataPartitions(dataMetaClient.getTableConfig());
-    
inflightIndexes.addAll(indexPartitionInfos.stream().map(HoodieIndexPartitionInfo::getMetadataPartitionPath).collect(Collectors.toSet()));
-    
dataMetaClient.getTableConfig().setValue(HoodieTableConfig.TABLE_METADATA_PARTITIONS_INFLIGHT.key(),
 String.join(",", inflightIndexes));
-    HoodieTableConfig.update(dataMetaClient.getFs(), new 
Path(dataMetaClient.getMetaPath()), dataMetaClient.getTableConfig().getProps());
-    initialCommit(indexUptoInstantTime + METADATA_INDEXER_TIME_SUFFIX, 
partitionTypes);
+
+    // before initialization set these  partitions as inflight in table config
+    HoodieTableMetadataUtil.setMetadataInflightPartitions(dataMetaClient, 
partitionTypes);

Review Comment:
   wrt 2nd flight. we should be cautious in updating table config on the fly. 



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

Reply via email to