【发布时间】:2018-12-31 09:19:10
【问题描述】:
我遇到了一个与 Kafka 相关的问题。
我正在使用我当前的服务 (Producer) 将消息发送到 Kafka 主题 (events)。该服务使用kafka_2.12 v1.0.0,用Java编写。
我正在尝试将它与spark-streaming 的示例项目集成为Consumer 服务(here 使用 kafka_2.11 v0.10.0,用 Scala 编写)
消息从Producer成功发送到Kafka主题。但是,我总是收到以下错误堆栈:
Exception in thread "main" org.apache.kafka.common.errors.InconsistentGroupProtocolException: The group member's supported protocols are incompatible with those of existing members.
at ... run in separate thread using org.apache.spark.util.ThreadUtils ... ()
at org.apache.spark.streaming.StreamingContext.liftedTree1$1(StreamingContext.scala:577)
at org.apache.spark.streaming.StreamingContext.start(StreamingContext.scala:571) at com.jj.streaming.ItemApp$.delayedEndpoint$com$jj$streaming$ItemApp$1(ItemApp.scala:72)
at com.jj.streaming.ItemApp$delayedInit$body.apply(ItemApp.scala:12)
at scala.Function0$class.apply$mcV$sp(Function0.scala:34)
at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:12) at scala.App$$anonfun$main$1.apply(App.scala:76)
at scala.App$$anonfun$main$1.apply(App.scala:76)
at scala.collection.immutable.List.foreach(List.scala:381)
at scala.collection.generic.TraversableForwarder$class.foreach(TraversableForwarder.scala:35) at scala.App$class.main(App.scala:76)
at com.jj.streaming.ItemApp$.main(ItemApp.scala:12)
at com.jj.streaming.ItemApp.main(ItemApp.scala)
我不知道根本原因。我该如何解决这个问题?
【问题讨论】:
-
Tin Nguyen,您找到解决方案了吗?我也面临同样的问题
-
嗨@Satish,不,我没有。
标签: apache-spark apache-kafka spark-streaming