8000 refactor: pass the `TaskContext` when execute physical plan rather than holding it by Rachelint · Pull Request #1163 · apache/horaedb · GitHub
[go: up one dir, main page]

Skip to content

Conversation

@Rachelint
Copy link
Contributor
@Rachelint Rachelint commented Aug 21, 2023

Rationale

Part of #1112
I found we holding the execution context in DataFusionPhysicalPlanImpl, rather than passing it as a param when executing like what datafusion suggests to do.

It lead to problems when I plan to deserialize bytes to DataFusionPhysicalPlanImpl...

Detailed Changes

  • Remove SessionContext from DataFusionPhysicalPlanImpl.
  • Pass it as a param when executing the plan.
  • Wrap all common part to DfContextBuilder and use it to build SessionContext in DatafusionExecutorImpl and DatafusionPhysicalPlannerImpl.

Test Plan

Test by exist tests.

@Rachelint Rachelint marked this pull request as ready for review August 21, 2023 11:53
Copy link
Member
@ShiKaiWi ShiKaiWi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Rachelint Rachelint merged commit 78e90e9 into apache:main Aug 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0