kafka-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mathias Herberts <mathias.herbe...@gmail.com>
Subject Re: Producer thread safety
Date Thu, 19 Sep 2013 10:01:47 GMT
Please ignore this report, the problem was triggered by another thread
clearing the list currently being sent.

Sorry for the noise.


On Thu, Sep 19, 2013 at 11:34 AM, Mathias Herberts <
mathias.herberts@gmail.com> wrote:

> Hi,
>
> I'm testing Kafka 0.8 and I encounter an error when accessing a Producer
> from mutliple threads.
>
> I've always thought Producer was thread safe but it seems this is no
> longer the case. This is the stack trace of the error I'm getting:
>
> java.util.ConcurrentModificationException
>     at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:819)
>     at java.util.ArrayList$Itr.next(ArrayList.java:791)
>     at
> scala.collection.JavaConversions$JIteratorWrapper.next(JavaConversions.scala:575)
>     at scala.collection.Iterator$class.foreach(Iterator.scala:772)
>     at
> scala.collection.JavaConversions$JIteratorWrapper.foreach(JavaConversions.scala:573)
>     at scala.collection.IterableLike$class.foreach(IterableLike.scala:73)
>     at
> scala.collection.JavaConversions$JListWrapper.foreach(JavaConversions.scala:615)
>     at kafka.producer.Producer.recordStats(Producer.scala:80)
>     at kafka.producer.Producer.send(Producer.scala:72)
>     at kafka.javaapi.producer.Producer.send(Producer.scala:41)
>
> Mathias.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message