Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
Kafka >> mail # user >> Re: Iterator Question


Copy link to this message
-
Re: Iterator Question
It is recommended you use the iterator() API since that invokes Kafka's
ConsumerIterator which has state management logic for consuming Kafka
messages properly. If you use toIterator(), it just gives you a plain Scala
iterator over KafkaStream.

Thanks,
Neha
On Tue, Oct 1, 2013 at 6:03 AM, Sybrandy, Casey <
[EMAIL PROTECTED]> wrote:

> Hello,
>
> What's the difference between the .toIterator() and .iterator() methods
> for KafkaStream?  I see they return different types and one of my coworkers
> is noticing that when he uses .toIterator() will block at times where
> .iterator() will not block.
>
> Casey
>
>

 
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB