kafka-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Matthias J. Sax" <matth...@confluent.io>
Subject Re: What is the best way to re-key a KTable?
Date Tue, 23 Jan 2018 21:14:03 GMT
Exactly. Because you might get multiple values with the same key, you
need to specify an aggregation to get a single value for each key.

-Matthias

On 1/23/18 9:14 AM, Dmitry Minkovsky wrote:
> KStream has a simple `#selectKey()` method, but it appears the only way to
> re-key a KTable is by doing `.toStream(mapper).groupByKey().reduce()`. Is
> this correct? I'm guessing this is because an attempt to re-key a table
> might result in multiple values at the new key.
> 


Mime
View raw message