You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by GitBox <gi...@apache.org> on 2021/06/07 14:13:00 UTC

[GitHub] [hudi] nsivabalan commented on a change in pull request #2049: [HUDI-1104] Adding support for UserDefinedPartitioners and SortModes to BulkInsert with Rows

nsivabalan commented on a change in pull request #2049:
URL: https://github.com/apache/hudi/pull/2049#discussion_r646626378



##########
File path: hudi-spark/src/main/java/org/apache/hudi/DataSourceUtils.java
##########
@@ -129,6 +132,25 @@ public static AbstractHoodieDateTimeParser createDateTimeParser(TypedProperties
     }
   }
 
+  /**
+   * Create a UserDefinedBulkInsertPartitionerRows class via reflection,
+   * <br>
+   * if the class name of UserDefinedBulkInsertPartitioner is configured through the HoodieWriteConfig.
+   *
+   * @see HoodieWriteConfig#getUserDefinedBulkInsertPartitionerClass()
+   */
+  public static Option<BulkInsertPartitioner<Dataset<Row>>> createUserDefinedBulkInsertPartitionerWithRows(HoodieWriteConfig config)
+      throws HoodieException {
+    String bulkInsertPartitionerClass = config.getUserDefinedBulkInsertPartitionerClass();

Review comment:
       I have not introduced a new config for this, but reusing the same used for BulkInsertPartitioner<HoodieRecord>. 
   Open to adding a new config if required. 




-- 
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:
users@infra.apache.org