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

ProducerPerformance doesn't support setting sasl.jaas.config as a --producer-props

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 0.11.0.1
    • None
    • tools
    • None

    Description

      I seems the parser expects everything to strictly be key=value pairs, where as sasl.jaas.config is key="preamble key=value key=value"

      Exception in thread "main" java.lang.IllegalArgumentException: Invalid property: sasl.jaas.config=org.apache.kafka.common.security.plain.PlainLoginModule required username='user' password='user-secret'";
      	at org.apache.kafka.tools.ProducerPerformance.main(ProducerPerformance.java:99)
      
                 if (producerProps != null)
                      for (String prop : producerProps) {
                          String[] pieces = prop.split("=");
                          if (pieces.length != 2)
                              throw new IllegalArgumentException("Invalid property: " + prop);
                          props.put(pieces[0], pieces[1]);
                      }
      

      Workaround is that user must instead put this in the --producer.config file.

      Attachments

        Activity

          People

            Unassigned Unassigned
            astubbs Antony Stubbs
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: