Migrate KStream to KTable conversion to use toTable() method

Proprietary

In Kafka Streams 2.5, a new toTable() method was added to simplify converting a KStream to a KTable. This recipe replaces the manual aggregation pattern .groupByKey().reduce((oldVal, newVal) -> newVal) with the more concise .toTable() method.

io.moderne.kafka.streams.MigrateKStreamToTable
mod run . --recipe=io.moderne.kafka.streams.MigrateKStreamToTable

Install it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.