[
https://issues.apache.org/jira/browse/CALCITE-3791?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Chunwei Lei resolved CALCITE-3791.
----------------------------------
Fix Version/s: 1.22.0
Resolution: Fixed
Fixed in
[https://github.com/apache/calcite/commit/b1e15d33783a38a8d896fe8203c68f61d5dbeca4].
> HepPlanner doesn't clear metadata cache for the ancestors of discarded node
> when a transformation happens
> ---------------------------------------------------------------------------------------------------------
>
> Key: CALCITE-3791
> URL: https://issues.apache.org/jira/browse/CALCITE-3791
> Project: Calcite
> Issue Type: Bug
> Components: core
> Reporter: Chunwei Lei
> Assignee: Chunwei Lei
> Priority: Major
> Labels: pull-request-available
> Fix For: 1.22.0
>
> Time Spent: 1h 40m
> Remaining Estimate: 0h
>
> In HepPlanner, when a transformation happens, it will clear metadata cache
> for the parent of the discarded node[1]. But it doesn't clear the metadata
> cache for the ancestors of the parent. For example, assume we get a logical
> plan like
> A
> \
> B
> \
> C
> , if we clear the metadata cache for C after applying a rule, we should also
> clear the metadata cache for A and B since metadata of A and B derive from C.
>
> [1][https://github.com/apache/calcite/blob/master/core/src/main/java/org/apache/calcite/plan/hep/HepPlanner.java#L877]
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)