pnowojski commented on a change in pull request #7087: [FLINK-10843] 
[connectors] Make Kafka table factory versioning more flexible
URL: https://github.com/apache/flink/pull/7087#discussion_r233097356
 
 

 ##########
 File path: 
flink-connectors/flink-connector-kafka-base/src/main/java/org/apache/flink/streaming/connectors/kafka/KafkaTableSourceSinkFactoryBase.java
 ##########
 @@ -249,7 +264,7 @@ private DescriptorProperties 
getValidatedProperties(Map<String, String> properti
 
                // allow Kafka timestamps to be used, watermarks can not be 
received from source
                new SchemaValidator(true, supportsKafkaTimestamps(), 
false).validate(descriptorProperties);
-               new KafkaValidator().validate(descriptorProperties);
+               new 
KafkaValidator(kafkaVersionPattern()).validate(descriptorProperties);
 
 Review comment:
   It's kind of strange that we validate the kafka version after the fact that 
we have already selected some kafka version (after all `this` instance has 
already a known Kafka version). This seems like either a duplicated logic or a 
kind of unit test that is perform during the runtime. Maybe it could be 
avoided/removed?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to