protected void createAutoBalancerMetricsProducer(Properties producerProps) throws KafkaException {
        AutoBalancerMetricsUtils.retry(() -> {
            try {
                producer = new KafkaProducer<>(producerProps);
                return false;
            } catch (KafkaException e) {
                if (e.getCause() instanceof ConfigException) {
                    // Check if the config exception is caused by bootstrap.servers config
                    try {
                        ProducerConfig config = new ProducerConfig(producerProps);
                        ClientUtils.parseAndValidateAddresses(
                                config.getList(ProducerConfig.BOOTSTRAP_SERVERS_CONFIG),
                                config.getString(ProducerConfig.CLIENT_DNS_LOOKUP_CONFIG));
                    } catch (ConfigException ce) {
                        // dns resolution may not be complete yet, let's retry again later
                        LOGGER.warn("Unable to create auto balancer metrics producer. ", ce.getCause());
                    }
                    return true;
                }
                throw e;
            }
        }, metricsReporterCreateRetries);
    }
On kafka metric removed

@param metric {@link KafkaMetric}
core/src/main/java/kafka/autobalancer/metricsreporter/AutoBalancerMetricsReporter.java