> On Feb. 27, 2015, 7:29 p.m., Gwen Shapira wrote:
> > Thanks for the patch, Ashish. Its shaping up to be a very useful example. 
> > Two comments:
> > 
> > 1. I think the ser/de should be part of the example and not in "common", 
> > I'm not sure integer ser/de is useful enough to be distributed with Kafka 
> > (although Jun can correct me if I got this wrong).
> > 
> > 2. I saw a lot of discussion on the mailing list around using the new 
> > producer async vs. sync. This example shows the async path. Do we want to 
> > add another "sync" example where we do something like:
> > val future = producer.send(new ProducerRecord<Integer, String>(topic,
> >              messageNo,
> >              messageStr), new DemoCallBack(startTime, messageNo, 
> > messageStr));
> > // this waits for send to complete
> > future.get

Gwen,

Integer may be a common type for keys. So, it probably makes sense to include 
Integer ser/de in common.

I agree that it would be useful to add a "sync" example.


- Jun


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/31369/#review74553
-----------------------------------------------------------


On Feb. 27, 2015, 7:08 p.m., Ashish Singh wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/31369/
> -----------------------------------------------------------
> 
> (Updated Feb. 27, 2015, 7:08 p.m.)
> 
> 
> Review request for kafka.
> 
> 
> Bugs: KAFKA-1982
>     https://issues.apache.org/jira/browse/KAFKA-1982
> 
> 
> Repository: kafka
> 
> 
> Description
> -------
> 
> KAFKA-1982: change kafka.examples.Producer to use the new java producer
> 
> 
> Diffs
> -----
> 
>   
> clients/src/main/java/org/apache/kafka/common/serialization/IntegerDeserializer.java
>  PRE-CREATION 
>   
> clients/src/main/java/org/apache/kafka/common/serialization/IntegerSerializer.java
>  PRE-CREATION 
>   examples/src/main/java/kafka/examples/Consumer.java 
> 13135b954f3078eeb7394822b0db25470b746f03 
>   examples/src/main/java/kafka/examples/Producer.java 
> 96e98933148d07564c1b30ba8e805e2433c2adc8 
> 
> Diff: https://reviews.apache.org/r/31369/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Ashish Singh
> 
>

Reply via email to