jeqo commented on a change in pull request #10381:
URL: https://github.com/apache/kafka/pull/10381#discussion_r604792476



##########
File path: 
streams/src/main/java/org/apache/kafka/streams/kstream/internals/KStreamPeek.java
##########
@@ -32,16 +33,16 @@ public KStreamPeek(final ForeachAction<K, V> action, final 
boolean forwardDownSt
     }
 
     @Override
-    public Processor<K, V> get() {
+    public Processor<K, V, K, V> get() {
         return new KStreamPeekProcessor();
     }
 
-    private class KStreamPeekProcessor extends AbstractProcessor<K, V> {
+    private class KStreamPeekProcessor extends AbstractProcessor<K, V, K, V> {
         @Override
-        public void process(final K key, final V value) {
-            action.apply(key, value);
+        public void process(final Record<K, V> record) {
+            action.apply(record.key(), record.value());
             if (forwardDownStream) {
-                context().forward(key, value);
+                context().forward(record);
             }

Review comment:
       It makes sense. Will give a try.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to