[ https://issues.apache.org/jira/browse/KAFKA-1507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14278929#comment-14278929 ]
Jay Kreps commented on KAFKA-1507: ---------------------------------- I think the right way to do this is have a proper create/delete/alter topic api (which i think is in-flight now). We should make having the get metadata request auto-creating topics optional and disable it by default (e.g. add an option like metadata.requests.auto.create=false). We can retain the auto-create functionality in the producer by having it issue this request in response to errors about a non-existant topic. I don't think we should change the java api of the producer to expose this (i.e. add a producer.createTopic(name, replication, partitions, etc). Instead I think we should consider a Java admin client that exposes this functionality. This would be where we would expose other operational apis as well. The rationale for this is that creating, deleting, and modifying topics is actually not part of normal application usage so having it directly exposed in the producer is a bit dangerous. We should definitely do a KIP proposal around this and get the design and API worked out first. I think we could do this in 0.8.3 if you are up to work on it. It would likely depend on some of the changes in KAFKA-1760 so we would want to merge that first. > Using GetOffsetShell against non-existent topic creates the topic > unintentionally > --------------------------------------------------------------------------------- > > Key: KAFKA-1507 > URL: https://issues.apache.org/jira/browse/KAFKA-1507 > Project: Kafka > Issue Type: Bug > Affects Versions: 0.8.1.1 > Environment: centos > Reporter: Luke Forehand > Assignee: Sriharsha Chintalapani > Priority: Minor > Labels: newbie > Attachments: KAFKA-1507.patch, KAFKA-1507.patch, > KAFKA-1507_2014-07-22_10:27:45.patch, KAFKA-1507_2014-07-23_17:07:20.patch, > KAFKA-1507_2014-08-12_18:09:06.patch, KAFKA-1507_2014-08-22_11:06:38.patch, > KAFKA-1507_2014-08-22_11:08:51.patch > > > A typo in using GetOffsetShell command can cause a > topic to be created which cannot be deleted (because deletion is still in > progress) > ./kafka-run-class.sh kafka.tools.GetOffsetShell --broker-list > kafka10:9092,kafka11:9092,kafka12:9092,kafka13:9092 --topic typo --time 1 > ./kafka-topics.sh --zookeeper stormqa1/kafka-prod --describe --topic typo > Topic:typo PartitionCount:8 ReplicationFactor:1 Configs: > Topic: typo Partition: 0 Leader: 10 Replicas: 10 > Isr: 10 > ... -- This message was sent by Atlassian JIRA (v6.3.4#6332)