JingsongLi commented on issue #10774: [FLINK-15485][tests] Reopen tests when 
blocking issue has been resolved.
URL: https://github.com/apache/flink/pull/10774#issuecomment-572489477
 
 
   Hi @leonardBang , about long join testing, you can modify to:
   ```
   @Test
     def testLongHashJoinGenerator(): Unit = {
       if (expectedJoinType == HashJoin) {
         val sink = (new CollectRowTableSink).configure(Array("c"), 
Array(Types.STRING))
         tEnv.registerTableSink("outputTable", sink)
         tEnv.insertInto("outputTable", tEnv.sqlQuery("SELECT c FROM 
SmallTable3, Table5 WHERE b = e"))
         val testingTEnv = tEnv.asInstanceOf[TestingTableEnvironment]
         val transforms = testingTEnv.getPlanner.asInstanceOf[PlannerBase]
             .translate(testingTEnv.getBufferedOperations)
         var haveTwoOp = false
   
         @scala.annotation.tailrec
         def findTwoInputTransform(t: Transformation[_]): 
TwoInputTransformation[_, _, _] = {
           t match {
             case sink: SinkTransformation[_] => 
findTwoInputTransform(sink.getInput)
             case one: OneInputTransformation[_, _] => 
findTwoInputTransform(one.getInput)
             case two: TwoInputTransformation[_, _, _] => two
           }
         }
   
         transforms.map(findTwoInputTransform).foreach { transform =>
           transform.getOperatorFactory match {
             case factory: CodeGenOperatorFactory[_] =>
               if 
(factory.getGeneratedClass.getCode.contains("LongHashJoinOperator")) {
                 haveTwoOp = true
               }
             case _ =>
           }
         }
         Assert.assertTrue(haveTwoOp)
       }
     }
   ```
   
   It's important, has triggered performance regression.

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


With regards,
Apache Git Services

Reply via email to