[ 
https://issues.apache.org/jira/browse/FLINK-5497?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15823884#comment-15823884
 ] 

ASF GitHub Bot commented on FLINK-5497:
---------------------------------------

Github user xhumanoid commented on the issue:

    https://github.com/apache/flink/pull/3089
  
    @StephanEwen 
    Hi, I did check more than double time
    
    This two part of code fully equals:
    
    ```java
    Tuple2<Integer, Integer> record;
    final Tuple2<Integer, Integer> recordReuse = new Tuple2<>();
    
    if (record = buildSide.next(recordReuse)  != null ) { .. }
    while (record = buildSide.next(record)  != null ) { .. } 
    ```
    
    ```java
    Tuple2<Integer, Integer> record;            
    final Tuple2<Integer, Integer> recordReuse = new Tuple2<>();
    
    if (record = buildSide.next(recordReuse)  != null ) { .. }
    while (record = buildSide.next(recordReuse)  != null ) { .. }
    ```
    
    after `if` record and recordReuse are pointing to one object.
    
    Other point it's comment:
    'This test is basically identical to the 
"testSpillingHashJoinWithMassiveCollisions" test, only that the number', 
    but when @aljoscha did refactoring (2 years ago) he replaced record =>  
recordReuse for one function (both place), but for second function replaced 
only in one place.
    
    p.s. i spent evening until unraveled this code from first commits =\


> remove duplicated tests
> -----------------------
>
>                 Key: FLINK-5497
>                 URL: https://issues.apache.org/jira/browse/FLINK-5497
>             Project: Flink
>          Issue Type: Improvement
>          Components: Tests
>            Reporter: Alexey Diomin
>            Priority: Minor
>
> Now we have test which run the same code 4 times, every run 17+ seconds.
> Need do small refactoring and remove duplicated code.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to