Re: one producer and 2 consumers

2013-04-26 Thread Chris Curtin
In a nutshell: High Level uses Consumer Groups to handle the tracking of message offset consumption. SimpleConsumer leaves it all up to you. The 0.7.x quick start shows examples of both: http://kafka.apache.org/quickstart.html On Fri, Apr 26, 2013 at 12:32 PM, Oleg Ruchovets wrote: > By the

Re: one producer and 2 consumers

2013-04-26 Thread Oleg Ruchovets
> Thanks, > > > > Jun > > > > > > On Fri, Apr 26, 2013 at 8:19 AM, Oleg Ruchovets > >wrote: > > > > > Hi. > > >I have simple kafka producer/consumer application. I have one > producer > > > and 2 consumers. consume

Re: one producer and 2 consumers

2013-04-26 Thread Chris Curtin
n http://kafka.apache.org/faq.html ? > > > > > > Thanks, > > > > > > Jun > > > > > > > > > On Fri, Apr 26, 2013 at 8:19 AM, Oleg Ruchovets > > >wrote: > > > > > > > Hi. > > > >I have simple

Re: one producer and 2 consumers

2013-04-26 Thread Oleg Ruchovets
t; > > > > Hi. > > >I have simple kafka producer/consumer application. I have one > producer > > > and 2 consumers. consumers has the same code , it is just executed it > in > > > different threads. For some reason information produced by producer > &

Re: one producer and 2 consumers

2013-04-26 Thread Chris Curtin
t 11:28 AM, Jun Rao wrote: > Have you looked at #4 in http://kafka.apache.org/faq.html ? > > Thanks, > > Jun > > > On Fri, Apr 26, 2013 at 8:19 AM, Oleg Ruchovets >wrote: > > > Hi. > >I have simple kafka producer/consumer application. I have one produ

Re: one producer and 2 consumers

2013-04-26 Thread Jun Rao
Have you looked at #4 in http://kafka.apache.org/faq.html ? Thanks, Jun On Fri, Apr 26, 2013 at 8:19 AM, Oleg Ruchovets wrote: > Hi. >I have simple kafka producer/consumer application. I have one producer > and 2 consumers. consumers has the same code , it is just execu

Re: one producer and 2 consumers

2013-04-26 Thread Oleg Ruchovets
Hi. I have simple kafka producer/consumer application. I have one producer and 2 consumers. consumers has the same code , it is just executed it in different threads. For some reason information produced by producer consumed only by ONE CONSUMER.Second consumer didn't consumed any inform

Re: one producer and 2 consumers

2013-04-21 Thread Philip O'Toole
OK, if you want each consumer to process the same data, then simply point each consumer at your Kafka cluster and have each Consumer consume all data. There is no synchronization required between those two consumers. In other words, what you want to do is fine. Please read the Kafka design doc if

Re: one producer and 2 consumers

2013-04-21 Thread Oleg Ruchovets
I am on POC stage , so I can configure the producer to write in different partitions. But how it will help me to process the same data with two consumers. I try to get such effect: I got the data and store it to Kafka. I have 2 consumers: 1) for real time which consumes the data for example

Re: one producer and 2 consumers

2013-04-21 Thread Philip O'Toole
On Sun, Apr 21, 2013 at 8:53 AM, Oleg Ruchovets wrote: > Hi Philip. >Does it mean to store the same data twice - each time to different > partition? I tried to save data only one time. Using two partitions means > to store data twice? No, I mean spreading the data across the two partitions, s

Re: one producer and 2 consumers

2013-04-21 Thread Oleg Ruchovets
Hi Philip. Does it mean to store the same data twice - each time to different partition? I tried to save data only one time. Using two partitions means to store data twice? By the way I am using kafka 0.7.2. Thanks Oleg. On Sun, Apr 21, 2013 at 11:30 AM, Philip O'Toole wrote: > Read the de

Re: one producer and 2 consumers

2013-04-21 Thread Philip O'Toole
Read the design doc on the Kafka site. The short answer is to use two partitions for your topic. Philip On Apr 21, 2013, at 12:37 AM, Oleg Ruchovets wrote: > Hi, > I have one producer for kafka and have 2 consumers. > I want to consume produced events to hdfs and storm. Copy to hdfs I will

one producer and 2 consumers

2013-04-21 Thread Oleg Ruchovets
Hi, I have one producer for kafka and have 2 consumers. I want to consume produced events to hdfs and storm. Copy to hdfs I will do every hour but to storm every 10 seconds. Question: Is it supported by kafka? Where can I read how to organize 1 producer and 2 consumers? Thanks Oleg.