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 2019/07/30 03:27:31 UTC
[GitHub] [incubator-hudi] eisig commented on a change in pull request #805:
fix DeltaStreamer writeConfig
eisig commented on a change in pull request #805: fix DeltaStreamer writeConfig
URL: https://github.com/apache/incubator-hudi/pull/805#discussion_r308519542
##########
File path: hoodie-utilities/src/main/java/com/uber/hoodie/utilities/deltastreamer/DeltaSync.java
##########
@@ -453,14 +453,16 @@ private HoodieWriteConfig getHoodieClientConfig(SchemaProvider schemaProvider) {
HoodieWriteConfig.Builder builder =
HoodieWriteConfig.newBuilder()
.withProps(props)
- .withPath(cfg.targetBasePath)
- .combineInput(cfg.filterDupes, true)
.withCompactionConfig(HoodieCompactionConfig.newBuilder()
+ .fromProperties(HoodieIndexConfig.newBuilder()
Review comment:
withProps(props) do add it, but withCompactionConfig would overwrite it with the default value.
for example, add 'hoodie.clean.automatic=false' with withProps(props), if it was not added to
HoodieCompactionConfig, the HoodieCompactionConfig build method would set default value:
```
setDefaultOnCondition(props, !props.containsKey(AUTO_CLEAN_PROP), AUTO_CLEAN_PROP,
DEFAULT_AUTO_CLEAN);
```
and
```
public Builder withCompactionConfig(HoodieCompactionConfig compactionConfig) {
props.putAll(compactionConfig.getProps());
isCompactionConfigSet = true;
return this;
}
```
would overwrite the props with that default value
so the HoodieWriteConfig would have 'hoodie.clean.automatic=true', that is the default value
----------------------------------------------------------------
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
With regards,
Apache Git Services