Giter Site home page Giter Site logo

Comments (4)

edenhill avatar edenhill commented on June 12, 2024

kafkacat uses the Kafka broker protocol's MetadataRequest to directly query the broker for cluster and topic metadata information, while kafka-topics.sh queries zookeeper for the same information.

Clearly one of those are out of sync in your printouts, and the information retrieved directly from Kafka brokers is usually authoritative (e.g., kafkacat > kafka-topics.sh), unless some of the brokers are acting up.

Could you log in to one of your broker VMs and run kafkacat once for each broker, explicitly providing -b <broker> for each call (where broker is the hostname reported in the metadata printout above, e.g.: ip-10-0-246-113.ec2.internal:9092)?
While this is probably exactly what dsh does, I'd like it to be a bit more explicit to rule out the case where just one of the brokers were queried.

from kcat.

fsaintjacques avatar fsaintjacques commented on June 12, 2024

Are you running with unsafe leader election?

from kcat.

charity avatar charity commented on June 12, 2024

Sorry for the delay. Found the problem -- kafka treats the "." character as a wildcard in topic names. And kafkacat will silently create a new topic if you describe it (unlike kafka-topic --describe). You can see in the first example, the topic is "hound-prod.retriever.mutation", and the second it is hound-prod.retriever-mutation".

Suggest making "kafkacat -D -t $topic" not create the topic if it doesn't exist, and instead behave the way "kafka-topics --topic --describe" does :)

from kcat.

edenhill avatar edenhill commented on June 12, 2024

The automatic topic creation is actually a broker side feature and config (auto.create.topics.enable=true), to avoid it you can list all topics (leave out the -t ..topic.. switch) and then do output filtering (preferably with JSON / jq)

from kcat.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.