srpanwar-confluent commented on a change in pull request #8723: URL: https://github.com/apache/kafka/pull/8723#discussion_r432145568
########## File path: clients/src/main/java/org/apache/kafka/clients/admin/KafkaAdminClient.java ########## @@ -2052,6 +2057,49 @@ void handleFailure(Throwable throwable) { return configSource; } + private ConfigEntry.ConfigType configType(DescribeConfigsResponse.ConfigType type) { + if (type == null) { + return ConfigEntry.ConfigType.UNKNOWN; + } + + ConfigEntry.ConfigType configType; + switch (type) { + case BOOLEAN: + configType = ConfigEntry.ConfigType.BOOLEAN; + break; + case CLASS: + configType = ConfigEntry.ConfigType.CLASS; + break; + case DOUBLE: + configType = ConfigEntry.ConfigType.DOUBLE; + break; + case INT: + configType = ConfigEntry.ConfigType.INT; + break; + case LIST: + configType = ConfigEntry.ConfigType.LIST; + break; + case LONG: + configType = ConfigEntry.ConfigType.LONG; + break; + case PASSWORD: + configType = ConfigEntry.ConfigType.PASSWORD; + break; + case SHORT: + configType = ConfigEntry.ConfigType.SHORT; + break; + case STRING: + configType = ConfigEntry.ConfigType.STRING; + break; + case UNKNOWN: + configType = ConfigEntry.ConfigType.UNKNOWN; + break; + default: + throw new IllegalArgumentException("Unexpected config type " + type); Review comment: hmm.. yes. ---------------------------------------------------------------- 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: us...@infra.apache.org