Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-2590 KIP-28: Kafka Streams Checklist
  3. KAFKA-3430

Allow users to set key in KTable.toStream() and KStream

    XMLWordPrintableJSON

    Details

    • Type: Sub-task
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.10.0.0
    • Fix Version/s: 0.10.0.0
    • Component/s: streams
    • Labels:

      Description

      Currently KTable.toStream does not take any parameters and hence users who wants to set the key need to do two steps:

      table.toStream().map(...)

      in order to do so. We can make it in one step by providing the mapper parameter in toStream.

      And similarly today users usually need to call

       KStream.map() 

      in order to select the key before aggregation-by-key operation if the original stream is does not contain keys.

      We can consider adding a specific function in KStream to do so:

      KStream.selectKey(mapper)

      which essential is the same as

      KStream.map(/* mapper that does not change the value, but only the key */)

        Attachments

          Activity

            People

            • Assignee:
              bbejeck Bill Bejeck
              Reporter:
              guozhang Guozhang Wang
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: