Skip to content

Commit

Permalink
Fix nits
Browse files Browse the repository at this point in the history
  • Loading branch information
yihua committed Feb 25, 2025
1 parent 978d9eb commit 5fe941a
Show file tree
Hide file tree
Showing 13 changed files with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public class JsonToAvroSchemaConverterConfig {
public static final ConfigProperty<Boolean> STRIP_DEFAULT_VALUE_QUOTES = ConfigProperty
.key("hoodie.streamer.schemaconverter.json_to_avro.strip_default_value_quotes")
.defaultValue(true)
.sinceVersion("0.14.1")
.sinceVersion("1.1.0")
.withDocumentation("In `org.apache.hudi.utilities.schema.converter.JsonToAvroSchemaConverter`, "
+ "whether to automatically strip the surrounding quotes on the default value of the "
+ "String-typed field in the schema. For example, the field schema is "
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@

package org.apache.hudi.utilities.sources;

import org.apache.hudi.client.WriteStatus;
import org.apache.hudi.avro.HoodieAvroUtils;
import org.apache.hudi.client.WriteStatus;
import org.apache.hudi.client.common.HoodieSparkEngineContext;
import org.apache.hudi.common.config.TypedProperties;
import org.apache.hudi.common.model.HoodieAvroRecord;
Expand Down Expand Up @@ -111,11 +111,11 @@ protected TypedProperties createPropsForKafkaSource(String topic, Long maxEvents

static TypedProperties createPropsForJsonKafkaSource(String brokerAddress, String topic, Long maxEventsToReadFromKafkaSource, String resetStrategy) {
TypedProperties props = new TypedProperties();
props.setProperty("hoodie.deltastreamer.source.kafka.topic", topic);
props.setProperty("hoodie.streamer.source.kafka.topic", topic);
props.setProperty("bootstrap.servers", brokerAddress);
props.setProperty("auto.offset.reset", resetStrategy);
props.setProperty(ConsumerConfig.ENABLE_AUTO_COMMIT_CONFIG, "false");
props.setProperty("hoodie.deltastreamer.kafka.source.maxEvents",
props.setProperty("hoodie.streamer.kafka.source.maxEvents",
maxEventsToReadFromKafkaSource != null ? String.valueOf(maxEventsToReadFromKafkaSource) :
String.valueOf(KafkaSourceConfig.MAX_EVENTS_FROM_KAFKA_SOURCE.defaultValue()));
props.setProperty(ConsumerConfig.GROUP_ID_CONFIG, UUID.randomUUID().toString());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@
}
},
"required": ["name", "gender"]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@
"doc" : "",
"type" : "string"
} ]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,4 @@
"default" : null,
"type" : "null"
} ]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -44,4 +44,4 @@
"$ref": "https://example.com/geographical-location.schema.json"
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -159,4 +159,4 @@
} ]
}
} ]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -96,4 +96,4 @@
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@
"doc" : "",
"type" : "double"
} ]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
"maximum": 180
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@
}
},
"required": [ "productId", "productName" ]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,4 @@
}
}
} ]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,4 @@
}
},
"required": [ "productId", "productName", "price" ]
}
}

0 comments on commit 5fe941a

Please sign in to comment.