raminqaf commented on code in PR #29133:
URL: https://github.com/apache/flink/pull/29133#discussion_r3987926034


##########
flink-streaming-java/src/test/java/org/apache/flink/streaming/api/DataStreamTest.java:
##########
@@ -836,6 +837,31 @@ public Long reduce(Long value1, Long value2) throws 
Exception {
                 .isEqualTo(preferredResource7);
     }
 
+    @Test
+    void testMapWithExplicitUuidType() {
+        final StreamExecutionEnvironment env = 
StreamExecutionEnvironment.getExecutionEnvironment();
+        // A lambda would bypass the input validation exercised by this test.
+        final MapFunction<UUID, String> mapper =
+                new MapFunction<UUID, String>() {
+                    @Override
+                    public String map(UUID value) {
+                        return value.toString();
+                    }
+                };

Review Comment:
   Can be simplified to:
   ```suggestion
           final MapFunction<UUID, String> mapper = UUID::toString;
   ```



-- 
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.

To unsubscribe, e-mail: [email protected]

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

Reply via email to