java.io.EOFException: Received -1 when reading from channel, socket has likely been closed.

Stack Overflow | ruben123 | 8 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    Not able to send json tweets events to Kafka topic/producer using kafka command line

    Stack Overflow | 8 months ago | ruben123
    java.io.EOFException: Received -1 when reading from channel, socket has likely been closed.

    Root Cause Analysis

    1. java.io.EOFException

      Received -1 when reading from channel, socket has likely been closed.

      at kafka.utils.CoreUtils$.read()
    2. Apache Kafka
      DefaultEventHandler$$anonfun$partitionAndCollate$1.apply
      1. kafka.utils.CoreUtils$.read(CoreUtils.scala:193)
      2. kafka.network.BoundedByteBufferReceive.readFrom(BoundedByteBufferReceive.scala:54)
      3. kafka.network.Receive$class.readCompletely(Transmission.scala:56)
      4. kafka.network.BoundedByteBufferReceive.readCompletely(BoundedByteBufferReceive.scala:29)
      5. kafka.network.BlockingChannel.receive(BlockingChannel.scala:131)
      6. kafka.producer.SyncProducer.liftedTree1$1(SyncProducer.scala:77)
      7. kafka.producer.SyncProducer.kafka$producer$SyncProducer$$doSend(SyncProducer.scala:74)
      8. kafka.producer.SyncProducer.send(SyncProducer.scala:115)
      9. kafka.client.ClientUtils$.fetchTopicMetadata(ClientUtils.scala:59)
      10. kafka.producer.BrokerPartitionInfo.updateInfo(BrokerPartitionInfo.scala:82)
      11. kafka.producer.BrokerPartitionInfo.getBrokerPartitionInfo(BrokerPartitionInfo.scala:49)
      12. kafka.producer.async.DefaultEventHandler.kafka$producer$async$DefaultEventHandler$$getPartitionListForTopic(DefaultEventHandler.scala:188)
      13. kafka.producer.async.DefaultEventHandler$$anonfun$partitionAndCollate$1.apply(DefaultEventHandler.scala:152)
      14. kafka.producer.async.DefaultEventHandler$$anonfun$partitionAndCollate$1.apply(DefaultEventHandler.scala:151)
      14 frames
    3. Scala
      ArrayBuffer.foreach
      1. scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59)
      2. scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47)
      2 frames
    4. Apache Kafka
      ProducerSendThread$$anonfun$processEvents$3.apply
      1. kafka.producer.async.DefaultEventHandler.partitionAndCollate(DefaultEventHandler.scala:151)
      2. kafka.producer.async.DefaultEventHandler.dispatchSerializedData(DefaultEventHandler.scala:96)
      3. kafka.producer.async.DefaultEventHandler.handle(DefaultEventHandler.scala:73)
      4. kafka.producer.async.ProducerSendThread.tryToHandle(ProducerSendThread.scala:105)
      5. kafka.producer.async.ProducerSendThread$$anonfun$processEvents$3.apply(ProducerSendThread.scala:88)
      6. kafka.producer.async.ProducerSendThread$$anonfun$processEvents$3.apply(ProducerSendThread.scala:68)
      6 frames
    5. Scala
      Stream.foreach
      1. scala.collection.immutable.Stream.foreach(Stream.scala:547)
      1 frame
    6. Apache Kafka
      ProducerSendThread.run
      1. kafka.producer.async.ProducerSendThread.processEvents(ProducerSendThread.scala:67)
      2. kafka.producer.async.ProducerSendThread.run(ProducerSendThread.scala:45)
      2 frames