其他分享
首页 > 其他分享> > kafka异常disconnected 处理

kafka异常disconnected 处理

作者:互联网

报错:Bootstrap broker basecoalmine:2181 (id: -1 rack: null) disconnected (org.apache.kafka.clients.NetworkClient) 

 

原因:未进行kafka鉴权

添加相关配置

spring:
  kafka:
    properties:
      sasl.mechanism: SCRAM-SHA-5
      security.protocol: SASL_PLAINTEXT
      sasl.jaas.config: org.apache.kafka.common.security.scram.ScramLoginModule required username="xxx" password="xxx";

 

标签:disconnected,kafka,sasl,apache,org,security,异常
来源: https://www.cnblogs.com/zycyc/p/16466067.html