You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "lfabriko (via GitHub)" <gi...@apache.org> on 2023/03/29 15:10:44 UTC

[GitHub] [camel-k] lfabriko commented on issue #4186: Unable to produce and consume in camel-k to apache kafka, getting error like "Connection to node -1 (localhost/127.0.0.1:9092) could not be established. Broker may not be available."

lfabriko commented on issue #4186:
URL: https://github.com/apache/camel-k/issues/4186#issuecomment-1488816404

   I think you can check `brokers` parameter if you have installed kafka (e.g. `my-kafka-cluster`) via 
   ```
   $ oc get kafka/my-kafka-cluster -o jsonpath="{.status.listeners[0].bootstrapServers}"
   my-kafka-cluster-kafka-bootstrap.lfabriko3.svc:9092
   ```
   
   Then I have in `KafkaProducer` (similarly in `KafkaConsumer`):
   `.to("kafka:myRecords?brokers=my-kafka-cluster-kafka-bootstrap.lfabriko3.svc:9092");` (or shortly `.to("kafka:myRecords?brokers=my-kafka-cluster-kafka-bootstrap:9092");`)
   
   (I suppose `myRecords` is the created kafka topic)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org