Github user kl0u commented on a diff in the pull request:

    https://github.com/apache/flink/pull/3484#discussion_r105399939
  
    --- Diff: 
flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/io/RecordWriterOutput.java
 ---
    @@ -72,6 +76,11 @@ public RecordWriterOutput(
     
    --- End diff --
    
    The bodies of the following two `collect(...)` methods are identical modulo 
the check for the output tag.
    It makes sense to put the common code in the same `private` method and call 
that method from each one of these (after doing the necessary checks). 
    
    As a side comment, should we just `return` if the wrong method is called or 
throw an exception ?
    
    This "Duplicate code" pattern appears some times in the code.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to