Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-4434

KafkaProducer configuration is logged twice

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 0.10.0.1
    • 0.10.2.0
    • config

    Description

      The constructor of org.apache.kafka.clients.producer.KafkaProducer accepts a ProducerConfig which when constructed logs the configuration: https://github.com/apache/kafka/blob/0.10.0.1/clients/src/main/java/org/apache/kafka/common/config/AbstractConfig.java#L58 .

      However, when the construction of KafkaProducer proceeds the provided ProducerConfig is repurposed and another instance is created https://github.com/apache/kafka/blob/0.10.0.1/clients/src/main/java/org/apache/kafka/clients/producer/KafkaProducer.java#L323 which triggers another log with the same contents (only the clientId can differ in case its not supplied in the original config).

      At first sight this seems like unintended behaviour to me. At least it caused me to dive into it in order to verify if there weren't two producer instances running.

      Attachments

        Issue Links

          Activity

            People

              huxi_2b huxihx
              rubendg Ruben de Gooijer
              Ismael Juma Ismael Juma
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: