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 2022/04/24 01:58:52 UTC

[GitHub] [hudi] YuweiXiao commented on a diff in pull request #4441: [HUDI-3085] improve bulk insert partitioner abstraction

YuweiXiao commented on code in PR #4441:
URL: https://github.com/apache/hudi/pull/4441#discussion_r857053826


##########
hudi-client/hudi-java-client/src/main/java/org/apache/hudi/table/action/commit/JavaBulkInsertHelper.java:
##########
@@ -119,7 +118,7 @@ public List<WriteStatus> bulkInsert(List<HoodieRecord<T>> inputRecords,
     new JavaLazyInsertIterable<>(repartitionedRecords.iterator(), true,
         config, instantTime, table,
         fileIdPrefixProvider.createFilePrefix(""), table.getTaskContextSupplier(),
-        new CreateHandleFactory<>()).forEachRemaining(writeStatuses::addAll);
+        (WriteHandleFactory) partitioner.getWriteHandleFactory(0).orElse(writeHandleFactory)).forEachRemaining(writeStatuses::addAll);

Review Comment:
   0 means getting write handle factory for partition 0. The code is consistent with previous behavior, as java engine always has only one data partition.



-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org