beyond1920 commented on a change in pull request #16025:
URL: https://github.com/apache/flink/pull/16025#discussion_r660396684



##########
File path: 
flink-table/flink-table-planner-blink/src/main/scala/org/apache/flink/table/planner/plan/rules/FlinkStreamRuleSets.scala
##########
@@ -486,7 +486,13 @@ object FlinkStreamRuleSets {
     // incremental agg rule
     IncrementalAggregateRule.INSTANCE,
     // optimize window agg rule
-    TwoStageOptimizedWindowAggregateRule.INSTANCE
-  )
+    TwoStageOptimizedWindowAggregateRule.INSTANCE,
+    // simplify window tvf
+    SimplifyWindowTableFunctionRule.WITH_CALC_WINDOW_RANK,
+    SimplifyWindowTableFunctionRule.WITH_WINDOW_RANK,
+    SimplifyWindowTableFunctionRule.WITH_LEFT_RIGHT_CALC_WINDOW_JOIN,
+    SimplifyWindowTableFunctionRule.WITH_LEFT_CALC_WINDOW_JOIN,
+    SimplifyWindowTableFunctionRule.WITH_RIGHT_CALC_WINDOW_JOIN,
+    SimplifyWindowTableFunctionRule.WITH_WINDOW_JOIN)

Review comment:
       I didn't put into `PHYSICAL_OPT_RULES ` because the rules could not work 
well in Cost-based-optimization phase.
   Because equivalent node didn't have less cost.




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