zhuqi-lucas commented on PR #21580:
URL: https://github.com/apache/datafusion/pull/21580#issuecomment-4296238432

   Re: https://github.com/apache/datafusion/pull/21580#discussion_r3123894244 
(@xudong963)
   
   Good point. Currently `create_filter` and `fetch` are set in the same method 
(`with_fetch`), and we fixed the ordering so `fetch` is set before 
`create_filter` is called. There's no separate code path that updates `fetch` 
without recreating the filter.
   
   But you're right that this coupling is fragile — if a future optimizer calls 
`with_fetch` independently, the filter's `fetch` would go stale. Tracked in 
#21780 as a follow-up to make `fetch` on `DynamicFilterPhysicalExpr` read 
directly from `SortExec.fetch` via a shared reference instead of copying at 
creation time.


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to