[
https://issues.apache.org/jira/browse/FLINK-31390?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
ASF GitHub Bot updated FLINK-31390:
-----------------------------------
Labels: pull-request-available (was: )
> Optimize the FlinkChangelogModeInferenceProgram by avoiding unnecessary
> traversals.
> -----------------------------------------------------------------------------------
>
> Key: FLINK-31390
> URL: https://issues.apache.org/jira/browse/FLINK-31390
> Project: Flink
> Issue Type: Improvement
> Components: Table SQL / Planner
> Reporter: Aitozi
> Priority: Minor
> Labels: pull-request-available
>
> We can avoid the unnecessary traversals of the RelNode tree, since we are
> only interested in the first satisfied plan.
>
> FlinkChangelogModeInferenceProgram
> {code:java}
> val updateKindTraitVisitor = new SatisfyUpdateKindTraitVisitor(context)
> val finalRoot = requiredUpdateKindTraits.flatMap {
> requiredUpdateKindTrait =>
> updateKindTraitVisitor.visit(rootWithModifyKindSet,
> requiredUpdateKindTrait)
> }
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)