JingsongLi commented on a change in pull request #10468: [FLINK-14649][table 
sql / api] Flatten all the connector properties keys to make it easy to 
configure in DDL
URL: https://github.com/apache/flink/pull/10468#discussion_r355122531
 
 

 ##########
 File path: 
flink-connectors/flink-connector-elasticsearch-base/src/main/java/org/apache/flink/table/descriptors/ElasticsearchValidator.java
 ##########
 @@ -87,7 +93,12 @@ private void validateHosts(DescriptorProperties properties) 
{
                hostsValidators.put(CONNECTOR_HOSTS_HOSTNAME, (key) -> 
properties.validateString(key, false, 1));
                hostsValidators.put(CONNECTOR_HOSTS_PORT, (key) -> 
properties.validateInt(key, false, 0, 65535));
                hostsValidators.put(CONNECTOR_HOSTS_PROTOCOL, (key) -> 
properties.validateString(key, false, 1));
-               properties.validateFixedIndexedProperties(CONNECTOR_HOSTS, 
false, hostsValidators);
+
+               if (properties.containsKey(CONNECTOR_HOSTS)) {
+                       validateAndGetHostsStr(properties);
 
 Review comment:
   Using Validators too?

----------------------------------------------------------------
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]


With regards,
Apache Git Services

Reply via email to