gharris1727 commented on code in PR #14309:
URL: https://github.com/apache/kafka/pull/14309#discussion_r1316480601


##########
connect/runtime/src/main/java/org/apache/kafka/connect/runtime/AbstractHerder.java:
##########
@@ -380,6 +387,110 @@ protected Map<String, ConfigValue> 
validateSourceConnectorConfig(SourceConnector
         return configDef.validateAll(config);
     }
 
+    private <T> ConfigInfos validateConverterConfig(
+            Map<String, String> connectorConfig,
+            ConfigValue converterConfigValue,
+            Class<T> converterInterface,
+            Function<T, ConfigDef> configDefAccessor,
+            String converterName,
+            String converterProperty,
+            ConverterType converterType

Review Comment:
   I believe this is the only thing which makes this a converter-specific 
function. All of the other logic appears generic across all plugin types. It 
could be replaced with a `Consumer<Map<String, String>>` function which mutates 
the config before it is passed to the plugin, or a `Function<Map<String, 
String>, Map<String, String>>` if you wanted to be pure.
   
   Then all of the variable names can just become `plugin` instead of 
`converter`.



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to