xushiyan commented on code in PR #8758:
URL: https://github.com/apache/hudi/pull/8758#discussion_r1233495175


##########
hudi-common/src/main/java/org/apache/hudi/common/table/HoodieTableMetaClient.java:
##########
@@ -465,6 +466,31 @@ public void validateTableProperties(Properties properties) 
{
     }
   }
 
+  /**
+   * Use this method to remove {@link 
HoodieTableConfig#TABLE_METADATA_PARTITIONS}
+   * and {@link HoodieTableConfig#TABLE_METADATA_PARTITIONS_INFLIGHT} during 
table
+   * init process as the metadata table is not initialized yet.
+   *
+   * @param props the original properties
+   * @return a {@link Pair} of which left is the updated {@link Properties} 
and right
+   * is removed {@link Properties}.
+   */
+  public static Pair<Properties, Properties> 
removeMetadataPartitionsProps(Properties props) {

Review Comment:
   this is obsolete due to https://github.com/apache/hudi/pull/9010



##########
hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/client/functional/TestHoodieBackedMetadata.java:
##########
@@ -2544,8 +2566,12 @@ public void testBootstrapWithTableNotFound() throws 
Exception {
     // delete the metadata folder.
     fs.delete(metadataTablePath, true);
     assertFalse(fs.exists(metadataTablePath));
+    Set<String> removingPropKeys = 
removeMetadataPartitionsProps(metaClient.getTableConfig().getProps())
+        
.getRight().keySet().stream().map(Object::toString).collect(Collectors.toSet());
+    Path metaPathDir = new Path(metaClient.getBasePathV2(), METAFOLDER_NAME);
+    HoodieTableConfig.delete(fs, metaPathDir, removingPropKeys);

Review Comment:
   this should use the new API to delete



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