n3nash commented on a change in pull request #2374:
URL: https://github.com/apache/hudi/pull/2374#discussion_r550852869
##########
File path:
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/client/AbstractHoodieWriteClient.java
##########
@@ -203,6 +208,45 @@ public boolean commitStats(String instantTime,
List<HoodieWriteStat> stats, Opti
return true;
}
+ public boolean commitStats(String instantTime, List<HoodieWriteStat> stats,
Option<Map<String, String>> extraMetadata,
+ String commitActionType, Map<String,
List<String>> partitionToReplaceFileIds) {
+
+ HoodieCommitMetadata metadata = CommitUtils.buildMetadata(stats,
partitionToReplaceFileIds, extraMetadata,
+ operationType, config.getSchema(), commitActionType);
+ if (config.isMultiWriterEnabled()) {
+ // get strategy and lock type
+ LockConfiguration lockConfiguration = new
LockConfiguration(config.getProps());
+ LockProvider lockProvider = (LockProvider)
ReflectionUtils.loadClass(config.getLockProviderClass(),
Review comment:
Already have it that way for `ConflictResolutionStrategy`, but this
reflection requires parameters hence kept it here. If we moved this to config
object, we have to make the getLockProviderClass parameterized which will be a
problem for clients to get just the class name. Other option is to have 2
overloaded getters. Let me know what you think.
----------------------------------------------------------------
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:
[email protected]