Wouldn't it be helpful to throw an error or a warning if the user tries to create a topic with an invalid name? Currently neither the API nor the CLI tools inform you that you are naming a topic in a way you shouldn't.
And as Otis pointed out elsewhere in this thread this ties back into the JMX/MBean issues related the usage of "-"/dashes and "_"/underscores, which are unfortunately the only non-alphanumeric characters that are at your disposal to add reasonable "structure" to your Kafka topic names. (https://issues.apache.org/jira/browse/KAFKA-1481) Do you mind sharing your topic naming convention at LinkedIn? --Michael On 11.09.2014 00:24, Jun Rao wrote: > We actually don't allow "." in the topic name. Topic name can be > alpha-numeric plus "-" and "_". > > Thanks, > > Jun > > On Tue, Sep 9, 2014 at 6:29 PM, Bhavesh Mistry > <mistry.p.bhav...@gmail.com> wrote: > >> Thanks, I was using without JMX. I will go through doc. But how >> about Topic or Metric name Topic Name Convention or Metric Name >> Convention ? The dot notation with topic having a ".". Any >> future plan to enforce some stand rules. >> >> Thanks, >> >> Bhavesh >> >> On Tue, Sep 9, 2014 at 3:38 PM, Jay Kreps <jay.kr...@gmail.com> >> wrote: >> >>> Hi Bhavesh, >>> >>> Each of those JMX attributes comes with documentation. If you >>> open up jconsole and attach to a jvm running the consumer you >>> should be able to read the descriptions for each attribute. >>> >>> -Jay >>> >>> On Tue, Sep 9, 2014 at 2:07 PM, Bhavesh Mistry >>> <mistry.p.bhav...@gmail.com> wrote: >>>> Kafka Team, >>>> >>>> Can you please let me know what each of following Metrics >>>> means ? Some >>> of >>>> them are obvious, but some are hard to understand. My Topic >>>> name is *TOPIC_NAME*. >>>> >>>> >>>> >>>> can we enforce a Topic Name Convention or Metric Name >>>> Convention. >>> Because >>>> in previous version of Kafka, we have similar issue of >>>> parsing Kafka Metrics name with host name issue (codahale >>>> lib) . I have topic name >>> with >>>> “.” So, it is hard to distinguish metric name and topic. >>>> Also, when guys get chance I would appreciate if you guys >>>> can explain metric description on wiki so community would >>>> know what to monitor. Please >> see >>>> below for full list of metrics from new producer. >>>> >>>> >>>> Thanks, >>>> >>>> Bhavesh >>>> >>>> >>>> record-queue-time-avg NaN *node-1.*request-latency-max >>>> -Infinity record-size-max -Infinity >>>> *node-1.*incoming-byte-rate NaN request-size-avg NaN >>>> *node-1.*request-latency-avg NaN *node-2.*request-size-avg >>>> NaN requests-in-flight 0.0 bufferpool-wait-ratio NaN >>>> network-io-rate NaN metadata-age 239.828 >>>> records-per-request-avg NaN record-retry-rate NaN >>>> buffer-total-bytes 6.7108864E7 buffer-available-bytes >>>> 6.7108864E7 topic.*TOPIC_NAME*.record-error-rate NaN >>>> record-send-rate NaN select-rate NaN >>>> node-2.outgoing-byte-rate NaN >>>> topic.*TOPIC_NAME*.record-retry-rate NaN batch-size-max >>>> -Infinity connection-creation-rate NaN >>>> node-1.outgoing-byte-rate NaN topic.*TOPIC_NAME*.byte-rate >>>> NaN waiting-threads 0.0 batch-size-avg NaN io-wait-ratio NaN >>>> io-wait-time-ns-avg NaN io-ratio NaN >>>> topic.TOPIC_NAME.record-send-rate NaN request-size-max >>>> -Infinity record-size-avg NaN request-latency-max -Infinity >>>> node-2.request-latency-max -Infinity record-queue-time-max >>>> -Infinity node-2.response-rate NaN node-1.request-rate NaN >>>> node-1.request-size-max -Infinity connection-count 3.0 >>>> incoming-byte-rate NaN compression-rate-avg NaN request-rate >>>> NaN node-1.response-rate NaN node-2.request-latency-avg NaN >>>> request-latency-avg NaN record-error-rate NaN >>>> connection-close-rate NaN *node-2.*request-size-max >>>> -Infinity topic.TOPIC_NAME.compression-rate NaN >>>> node-2.incoming-byte-rate NaN node-1.request-size-avg NaN >>>> io-time-ns-avg NaN outgoing-byte-rate NaN >>>> *node-2*.request-rate NaN response-rate NaN >>> >> >