You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by mj...@apache.org on 2022/07/07 21:00:16 UTC
[kafka] branch trunk updated: KAFKA-12943: update aggregating documentation (#12091)
This is an automated email from the ASF dual-hosted git repository.
mjsax pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/kafka.git
The following commit(s) were added to refs/heads/trunk by this push:
new 63a6130af30 KAFKA-12943: update aggregating documentation (#12091)
63a6130af30 is described below
commit 63a6130af30536d67fca5802005695a84c875b5e
Author: Marco Aurelio Lotz <co...@marcolotz.com>
AuthorDate: Thu Jul 7 23:00:05 2022 +0200
KAFKA-12943: update aggregating documentation (#12091)
Reviewers: Luke Chen <sh...@gmail.com>, Andrew Eugene Choi <an...@uwaterloo.ca>, Matthias J. Sax <ma...@confluent.io>
---
docs/streams/developer-guide/dsl-api.html | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/docs/streams/developer-guide/dsl-api.html b/docs/streams/developer-guide/dsl-api.html
index 3d8454abb20..6b80656ef22 100644
--- a/docs/streams/developer-guide/dsl-api.html
+++ b/docs/streams/developer-guide/dsl-api.html
@@ -956,7 +956,7 @@ KGroupedTable<byte[], String> groupedTable = ...;
KTable<byte[], Long> aggregatedStream = groupedStream.aggregate(
() -> 0L, /* initializer */
(aggKey, newValue, aggValue) -> aggValue + newValue.length(), /* adder */
- Materialized.as("aggregated-stream-store") /* state store name */
+ Materialized.<String, Long, KeyValueStore<Bytes, byte[]>>as("aggregated-stream-store") /* state store name */
.withValueSerde(Serdes.Long()); /* serde for aggregate value */
// Aggregating a KGroupedTable (note how the value type changes from String to Long)
@@ -964,7 +964,7 @@ KTable<byte[], Long> aggregatedTable = groupedTable.aggregate(
() -> 0L, /* initializer */
(aggKey, newValue, aggValue) -> aggValue + newValue.length(), /* adder */
(aggKey, oldValue, aggValue) -> aggValue - oldValue.length(), /* subtractor */
- Materialized.as("aggregated-table-store") /* state store name */
+ Materialized.<String, Long, KeyValueStore<Bytes, byte[]>>as("aggregated-table-store") /* state store name */
.withValueSerde(Serdes.Long()) /* serde for aggregate value */