[ 
https://issues.apache.org/jira/browse/FLINK-20509?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

godfrey he updated FLINK-20509:
-------------------------------
    Description: 
 Currently, we use {{verifyPlan}} method to verify the plan result for both 
{{RelNode}} plan and {{ExecNode}} plan, because their instances are the same. 
But once the implementation of {{RelNode}} and {{ExecNode}} are separated, we 
can't get {{ESTIMATED_COST}} and {{CHANGELOG_MODE}} on {{ExecNode}} plan. So in 
order to make those methods more clear, we will do the following refactoring:
1. replace {{planBefore}} with {{ast}} in xml file. {{ast}} is "Abstract Syntax 
Tree", corresponding to "Abstract Syntax Tree" item in the explain result; 
2. remove {{planAfter}}, introduce  {{optimized rel plan}} and {{optimized exec 
plan}}. {{optimized rel plan}}  is the optimized rel plan, and is similar to 
"Optimized Physical Plan" item in the explain result. but different from 
"Optimized Physical Plan", {{optimized rel plan}} can represent either 
optimized logical rel plan (for rule testing) or optimized physical rel plan 
(for changelog validation, etc). {{optimized exec plan}} is the optimized 
execution plan, corresponding to "Optimized Execution Plan" item in the explain 
result. see https://issues.apache.org/jira/browse/FLINK-20478 for more details 
about explain refactor
3. keep {{verifyPlan}} method, which will print {{ast}}, {{optimized rel plan}} 
and {{optimized exec plan}}. 
4. add {{verifyRelPlan}} method, which will print {{ast}}, {{optimized rel 
plan}}
5. add {{verifyExecPlan}} method, which will print {{ast}} and {{optimized exec 
plan}}. 

  was:
 Currently, we use {{verifyPlan}} method to verify the plan result for both 
{{RelNode}} plan and {{ExecNode}} plan, because their instances are the same. 
But once the implementation of {{RelNode}} and {{ExecNode}} are separated, we 
can't get {{ESTIMATED_COST}} and {{CHANGELOG_MODE}} on {{ExecNode}} plan. So in 
order to make those methods more clear, we will do the following refactoring:
1. replace {{planBefore}} with {{ast}} in xml file. {{ast}} is "Abstract Syntax 
Tree", corresponding to "Abstract Syntax Tree" item in the explain result; 
2. remove {{planAfter}}, introduce  {{optimized rel plan}} and {{optimized exec 
plan}}. {{optimized rel plan}}  is the optimized rel plan, and is similar to 
"Optimized Physical Plan" item in the explain result. but different from 
"Optimized Physical Plan", {{optimized rel plan}} can represent either 
optimized logical rel plan (for rule testing) or optimized physical rel plan 
(for changelog validation, etc). {{optimized exec plan}} is the optimized 
execution plan, corresponding to "Optimized Execution Plan" item in the explain 
result. see https://issues.apache.org/jira/browse/FLINK-20478 for more details 
about explain refactor
2. keep {{verifyPlan}} method, which will print {{ast}}, {{optimized rel plan}} 
and {{optimized exec plan}}. 
3. add {{verifyRelPlan}} method, which will print {{ast}}, {{optimized rel 
plan}}
4. add {{verifyExecPlan}} method, which will print {{ast}} and {{optimized exec 
plan}}. 


> Refactor verifyPlan method in TableTestBase
> -------------------------------------------
>
>                 Key: FLINK-20509
>                 URL: https://issues.apache.org/jira/browse/FLINK-20509
>             Project: Flink
>          Issue Type: Sub-task
>          Components: Table SQL / Planner
>            Reporter: godfrey he
>            Assignee: godfrey he
>            Priority: Major
>              Labels: pull-request-available
>
>  Currently, we use {{verifyPlan}} method to verify the plan result for both 
> {{RelNode}} plan and {{ExecNode}} plan, because their instances are the same. 
> But once the implementation of {{RelNode}} and {{ExecNode}} are separated, we 
> can't get {{ESTIMATED_COST}} and {{CHANGELOG_MODE}} on {{ExecNode}} plan. So 
> in order to make those methods more clear, we will do the following 
> refactoring:
> 1. replace {{planBefore}} with {{ast}} in xml file. {{ast}} is "Abstract 
> Syntax Tree", corresponding to "Abstract Syntax Tree" item in the explain 
> result; 
> 2. remove {{planAfter}}, introduce  {{optimized rel plan}} and {{optimized 
> exec plan}}. {{optimized rel plan}}  is the optimized rel plan, and is 
> similar to "Optimized Physical Plan" item in the explain result. but 
> different from "Optimized Physical Plan", {{optimized rel plan}} can 
> represent either optimized logical rel plan (for rule testing) or optimized 
> physical rel plan (for changelog validation, etc). {{optimized exec plan}} is 
> the optimized execution plan, corresponding to "Optimized Execution Plan" 
> item in the explain result. see 
> https://issues.apache.org/jira/browse/FLINK-20478 for more details about 
> explain refactor
> 3. keep {{verifyPlan}} method, which will print {{ast}}, {{optimized rel 
> plan}} and {{optimized exec plan}}. 
> 4. add {{verifyRelPlan}} method, which will print {{ast}}, {{optimized rel 
> plan}}
> 5. add {{verifyExecPlan}} method, which will print {{ast}} and {{optimized 
> exec plan}}. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to