当前位置:   article > 正文

SpringBoot整合kafka报could not be established. Broker may not be available.

could not be established. broker may not be available

SpringBoot整合kafka报could not be established. Broker may not be available.

报错日志

[AdminClient clientId=adminclient-1] Connection to node 0 (localhost/127.0.0.1:9092) could not be established. Broker may not be available.
[AdminClient clientId=adminclient-1] Connection to node 0 (localhost/127 .0.0.1:9092) could not be established. Broker may not be available.
[AdminClient client Id=adminclient-1] Connection to node 0 (localhost/127 .0.0.1:9092) could not be established. Broker may not be available.
[AdminClient clientId= adminclient-1] Connection to node 0 (localhost/127 .0.0.1:9092) could not be established. Broker may not be available.
[AdminClient clientId=adminclient-1] Connection to node 0 (localhost/127 .0.0.1:9092) could not be established. Broker may not be available.
[AdminClient client Id=adminclient-1] Connection to node 0 (localhost/127 .0.0.1:9092) could not be established. Broker may not be available.
[ AdminClient client Id-adminclient-1] Connection to node 0 (localhost/127 .0.0.1:9092) could not be established. Broker may not be available.
[AdminClient client Id=adminclient-1] Connection to node 0 (localhost/127 .0.0.1:9092) could not be established. Broker may not be available.
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8

解决,修改kafka的server.properties

listeners=PLAINTEXT://kafka-host:9092
advertised.listeners=PLAINTEXT://kafka-host:9092
  • 1
  • 2

例如:
在这里插入图片描述

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/很楠不爱3/article/detail/533350
推荐阅读
相关标签
  

闽ICP备14008679号