Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-1326 New consumer checklist
  3. KAFKA-2275

Add a ListTopics() API to the new consumer

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • None
    • 0.9.0.0
    • consumer
    • None

    Description

      With regex subscription like

      consumer.subscribe("topic*")
      

      The partition assignment is automatically done at the Kafka side, while there are some use cases where consumers want regex subscriptions but not Kafka-side partition assignment, rather with their own specific partition assignment. With ListTopics() they can periodically check for topic list changes and specifically subscribe to the partitions of the new topics.

      For implementation, it involves sending a TopicMetadataRequest to a random broker and parse the response.

      Attachments

        1. KAFKA-2275_2015-07-17_21:39:27.patch
          14 kB
          Ashish Singh
        2. KAFKA-2275_2015-07-20_10:44:19.patch
          23 kB
          Ashish Singh
        3. KAFKA-2275_2015-07-22_16:09:34.patch
          24 kB
          Ashish Singh
        4. KAFKA-2275_2015-07-23_09:34:41.patch
          28 kB
          Ashish Singh
        5. KAFKA-2275.patch
          12 kB
          Ashish Singh
        6. KAFKA-2275.patch
          7 kB
          Ashish Singh

        Issue Links

          Activity

            People

              singhashish Ashish Singh
              guozhang Guozhang Wang
              Guozhang Wang Guozhang Wang
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: