Skip to content

feat: Stage based fallback#4519

Open
karuppayya wants to merge 2 commits into
apache:mainfrom
karuppayya:COMET-4518
Open

feat: Stage based fallback#4519
karuppayya wants to merge 2 commits into
apache:mainfrom
karuppayya:COMET-4518

Conversation

@karuppayya
Copy link
Copy Markdown
Contributor

Which issue does this PR close?

Closes #4518 .

Rationale for this change

Introduces a stage-aware fallback that reverts stages to Spark row-based execution when the number of C2R transitions exceeds a threshold.

What changes are included in this PR?

  • RevertNativeForTransitionHeavyStagespostColumnarTransitions rule that counts C2R transitions per stage and reverts via CometExec.originalPlan when threshold exceeded
  • Configs: spark.comet.exec.transitionRevert.enabled (default: true), spark.comet.exec.transitionRevert.maxTransitions (default: 2, min: 2)
  • Works for both AQE and non-AQE paths

How are these changes tested?

Unit tests added

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.

Revert transition-heavy stages to Spark row-based execution

2 participants