Hi Richard,

Thanks a lot for the KIP!

I have three question:
 - why is the new merge() method static?
 - why does the new merge() method take StreamsBuilder as a parameter?
 - did you think about Xavier's comment (see the JIRA in case you did
not notice it yet) about varargs vs adding some overloads to merge stream?

My personal take is that merge() should not be static and not take
StreamsBuilder. The idea of the JIRA was to get a more natural API:

// old
KStream merged = StreamsBuilder.merge(stream1, stream2);
// new
KStream merge = stream1.merge(stream2);


Having pointed out the second pattern, it should actually be fine to get
rid of varargs in merger() at all, as users could chain multiple calls
to merge() after each other:

KStream multiMerged = stream1.merge(s2).merge(s3).merge(s4);




-Matthias

On 9/16/17 9:36 PM, Richard Yu wrote:
> Hi,
> Please take a look at:
> 
> https://cwiki.apache.org/confluence/display/KAFKA/KIP-
> 202+Move+merge%28%29+from+StreamsBuilder+to+KStream
> 
> Thanks
> 

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to