From 4a81df7d1547ef026ea18455b97588793a686a4e Mon Sep 17 00:00:00 2001 From: "Matthias J. Sax" Date: Wed, 26 Nov 2025 19:40:43 -0800 Subject: [PATCH 1/3] MINOR: improve Kafka Streams transform upgrade docs We should also mention `flatTransformValues` method. --- docs/streams/developer-guide/dsl-api.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/streams/developer-guide/dsl-api.html b/docs/streams/developer-guide/dsl-api.html index 2c7c959a637ec..51ffbde3ebdf9 100644 --- a/docs/streams/developer-guide/dsl-api.html +++ b/docs/streams/developer-guide/dsl-api.html @@ -3462,7 +3462,8 @@

The Processor API now serves as a unified replacement for all these methods. It simplifies the API surface while maintaining support for both stateless and stateful operations.

-

CAUTION: If you are using KStream.transformValues() and you have the "merge repartition topics" +

CAUTION: If you are using KStream.transformValues() or KStream.flatTransformValues() + and you have the "merge repartition topics" optimization enabled, rewriting your program to KStream.processValues() might not be safe due to KAFKA-19668. For this case, you should not upgrade to Kafka Streams 4.0.0 or 4.1.0, but use Kafka Streams 4.0.1 instead, which contains a fix. From 045399f126f55976a552d3717473dc62bd197152 Mon Sep 17 00:00:00 2001 From: "Matthias J. Sax" Date: Wed, 26 Nov 2025 19:49:32 -0800 Subject: [PATCH 2/3] add version --- docs/streams/developer-guide/dsl-api.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/streams/developer-guide/dsl-api.html b/docs/streams/developer-guide/dsl-api.html index 51ffbde3ebdf9..c9ae53bdd33c4 100644 --- a/docs/streams/developer-guide/dsl-api.html +++ b/docs/streams/developer-guide/dsl-api.html @@ -3466,7 +3466,7 @@

and you have the "merge repartition topics" optimization enabled, rewriting your program to KStream.processValues() might not be safe due to KAFKA-19668. For this case, you should not upgrade - to Kafka Streams 4.0.0 or 4.1.0, but use Kafka Streams 4.0.1 instead, which contains a fix. + to Kafka Streams 4.0.0 or 4.1.0, but use Kafka Streams 4.0.1 or 4.1.1 instead, which contain a fix. Note, that the fix is not enabled by default for backward compatibility reasons, and you would need to enable the fix by setting config __enable.process.processValue.fix__ = true and pass it into StreamsBuilder() constructor.

From a06b0ebc679616066175f6874bd7ce0111748ed9 Mon Sep 17 00:00:00 2001 From: "Matthias J. Sax" Date: Wed, 26 Nov 2025 20:10:15 -0800 Subject: [PATCH 3/3] add missing paragraph --- docs/streams/developer-guide/dsl-api.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/streams/developer-guide/dsl-api.html b/docs/streams/developer-guide/dsl-api.html index c9ae53bdd33c4..e71fafe55ead1 100644 --- a/docs/streams/developer-guide/dsl-api.html +++ b/docs/streams/developer-guide/dsl-api.html @@ -3681,6 +3681,8 @@
Replacing Slang in Text Messag } }
Cumulative Discounts for a Loyalty Program
+

Below, methods applyDiscountWithTransform and applyDiscountWithProcess show how you can + migrate from transform to process.

public class CumulativeDiscountsForALoyaltyProgramExample {
     private static final double DISCOUNT_THRESHOLD = 100.0;
     private static final String CUSTOMER_SPENDING_STORE = "customer-spending-store";