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

Kafka does not create topic automatically after deleting the topic.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Not A Problem
    • 0.8.2.0
    • 0.8.2.0
    • admin
    • None
    • Ubuntu 14.04 LTS

    Description

      After I create a topic and then remove it (and wait for enough time to eventually delete it), it does not create a topic emitting errors even though auto-create topic option is true. It works okay when I manually create a topic after deleting it.

      Here is the command I run.

      ./bin/kafka-topics.sh --list --zookeeper 192.168.0.190:2181
      test

      ./bin/kafka-topics.sh --delete --zookeeper 192.168.0.190:2181 --topic test

      bin/kafka-console-producer.sh --broker-list localhost:9092 --topic test
      [2015-04-06 20:51:44,542] WARN Property topic is not valid (kafka.utils.VerifiableProperties)
      test
      [2015-04-06 20:51:49,896] WARN Error while fetching metadata [

      {TopicMetadata for topic test -> No partition metadata for topic test due to kafka.common.LeaderNotAvailableException}

      ] for topic [test]: class kafka.common.LeaderNotAvailableException (kafka.producer.BrokerPartitionInfo)
      [2015-04-06 20:51:49,904] WARN Error while fetching metadata [

      {TopicMetadata for topic test-> No partition metadata for topic testdue to kafka.common.LeaderNotAvailableException}

      ] for topic [test]: class kafka.common.LeaderNotAvailableException (kafka.producer.BrokerPartitionInfo)
      [2015-04-06 20:51:49,905] ERROR Failed to collate messages by topic, partition due to: Failed to fetch topic metadata for topic: test(kafka.producer.async.DefaultEventHandler)
      ^Csnowdrop@master:~/workspace/kafka/kafka_2.10-0.8.2.0$ bin/kafka-console-producer.sh --broker-list localhost:9092 --topic test
      [2015-04-06 20:52:08,733] WARN Property topic is not valid (kafka.utils.VerifiableProperties)

      Server side, I got this error

      [2015-04-06 21:41:08,491] ERROR [Replica Manager on Broker 0]: Error when processing fetch request for partition [test,0] offset 1687 from consumer with correlation id 5. Possible cause: Request for offset 1687 but we only have log segments in the range 0 to 107. (kafka.server.ReplicaManager)

      Attachments

        Activity

          People

            Unassigned Unassigned
            gurwls223 Hyukjin Kwon
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: