java的api 消费kafka报错,,java.lang.NoClassDefFoundError: org/apache/kafka/common/security/JaasUtils
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/kafka/common/security/JaasUtils
at kafka.consumer.ZookeeperConsumerConnector.connectZk(ZookeeperConsumerConnector.scala:184)
at kafka.consumer.ZookeeperConsumerConnector.<init>(ZookeeperConsumerConnector.scala:129)
at kafka.javaapi.consumer.ZookeeperConsumerConnector.<init>(ZookeeperConsumerConnector.scala:66)
at kafka.javaapi.consumer.ZookeeperConsumerConnector.<init>(ZookeeperConsumerConnector.scala:69)
at kafka.consumer.Consumer$.createJavaConsumerConnector(ConsumerConnector.scala:120)
at kafka.consumer.Consumer.createJavaConsumerConnector(ConsumerConnector.scala)
at org.apache.spark.examp.SimpleConsumer.<init>(SimpleConsumer.java:29)
at org.apache.spark.examp.SimpleConsumer.main(SimpleConsumer.java:24)
Caused by: java.lang.ClassNotFoundException: org.apache.kafka.common.security.JaasUtils
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
兄弟问题找到了吗