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

Kafka Server does not accept 0 as a port

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 0.8.2.1
    • None
    • config
    • None

    Description

      I want to specify 0 as a port number for Zookeeper as well as Kafka Server. For instance server.properties configuration file has a 'port' property, but does not accept 0 as a value. Similarly, zookeeper.properties has a 'clientPort' property, but does not accept 0 as a value.

      I want 0 to specify that the port will be selected automatically (OS assigned). In my use case, I want to run Zookeeper with an automatically picked port, and use that port to create a Kafka Server configuration file, that specifies the Kafka Server port as 0 as well. I parse the output from the servers to figure out the actual ports used. All this is needed for a testing environment.

      Not supporting automatically selected ports makes it difficult to run Kafka server as part of our tests.

      Attachments

        Activity

          People

            Unassigned Unassigned
            bgedik Bu─čra Gedik
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: