prashantwason commented on code in PR #18182:
URL: https://github.com/apache/hudi/pull/18182#discussion_r3230491615


##########
hudi-common/src/main/java/org/apache/hudi/metadata/HoodieTableMetadataUtil.java:
##########
@@ -2281,6 +2298,78 @@ public static String 
deleteMetadataTablePartition(HoodieTableMetaClient dataMeta
     return null;
   }
 
+  /**
+   * Returns true if bucketing is enabled for the metadata table.
+   *
+   * @param metaClient MetaClient for the metadata table
+   * @return true if bucketing is enabled
+   */
+  private static boolean isBucketingEnabledForMDT(HoodieTableMetaClient 
metaClient) {
+    // Bucketing status is saved within the main dataset's properties.
+    String basePath = 
HoodieTableMetadata.getDataTableBasePathFromMetadataTable(metaClient.getBasePath().toString());
+    return HoodieTableMetaClient.builder()

Review Comment:
   Fixed in 39755a7e. The bucketing flag is now also persisted on the MDT's own 
`hoodie.properties` (in `setMetadataTablePartitionBucketing`), and 
`isBucketingEnabledForMDT` reads it directly from 
`metaClient.getTableConfig().isMetadataTablePartitionBucketingEnabled()`. The 
per-call disk read of the data table's properties is gone.



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