Re: Fwd: Java NPE in using KafkaConsumer API

2015-06-22 Thread Tomas Gradin
Hi, please please throw an UnsupportedOperationException form unimplemented methods instead of just returning null! I'm talking about the poll() method in KafkaConsumer. I just spent two hours trying to figure out why I always got null from it... Best regards, Tomas G.

Re: Java NPE in using KafkaConsumer API

2015-06-19 Thread Sandeep Bishnoi
Sorry its too late to reply. But I was using 0.8.2. ~ Sandeep

Re: Java NPE in using KafkaConsumer API

2015-04-06 Thread Guozhang Wang
Hi Sandeep / Alec, I have been testing on trunk's KafkaConsumer with partition subscription only, and it works for me. The topic subscription does not work yet as we are still implementing that feature. Could you confirm if you are using trunk's KafkaConsumer and subscribe to partitions? Guozhan

Re: Java NPE in using KafkaConsumer API

2015-03-30 Thread Jay Kreps
Are you using the 0.8.2 release or trunk? -Jay On Mon, Mar 30, 2015 at 1:35 AM, Sandeep Bishnoi < sandeepbishnoi.b...@gmail.com> wrote: > Hi, > > I have configured a kafka consumer as follows: > Properties props = new Properties(); > // .. > // Populated properties > Kafka

Re: Fwd: Java NPE in using KafkaConsumer API

2015-03-30 Thread Alec Ten Harmsel
On 03/30/2015 04:35 AM, Sandeep Bishnoi wrote: > > The consumer.poll() api is returning null always. Although the remaining > code is based on the returned value from poll. > > Can you please let me know whether > org.apache.kafka.clients.consumer.KafkaConsumer is a valid API to use if I > wa

Fwd: Java NPE in using KafkaConsumer API

2015-03-30 Thread Sandeep Bishnoi
Hi, I have configured a kafka consumer as follows: Properties props = new Properties(); // .. // Populated properties KafkaConsumer consumer = new KafkaConsumer(props); // subscribe to partition "0" of topic test TopicPartition partition0 = new TopicPartition("test"