danny0405 commented on code in PR #17994:
URL: https://github.com/apache/hudi/pull/17994#discussion_r2726338963
##########
hudi-flink-datasource/hudi-flink/src/main/java/org/apache/hudi/configuration/OptionsResolver.java:
##########
@@ -151,13 +152,28 @@ public static boolean
isDefaultHoodieRecordPayloadClazz(Configuration conf) {
return
conf.get(FlinkOptions.PAYLOAD_CLASS_NAME).contains(DefaultHoodieRecordPayload.class.getSimpleName());
}
+ /**
+ * Return value of {@link FlinkOptions#RECORD_KEY_FIELD} if it was set,
+ * or throw exception otherwise.
+ */
+ public static String getRecordKeyStrOrFail(Configuration conf) {
+ final String recordKeyStr = conf.get(FlinkOptions.RECORD_KEY_FIELD);
+ if (null == recordKeyStr) {
Review Comment:
let's move these null check into `HoodieTableFactory`?
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]