Skip to content

[AURON #2022] [BUG] Native engine panic on closed channel causes JVM crash.#2023

Open
slfan1989 wants to merge 1 commit intoapache:masterfrom
slfan1989:auron-2022
Open

[AURON #2022] [BUG] Native engine panic on closed channel causes JVM crash.#2023
slfan1989 wants to merge 1 commit intoapache:masterfrom
slfan1989:auron-2022

Conversation

@slfan1989
Copy link
Contributor

@slfan1989 slfan1989 commented Feb 18, 2026

Which issue does this PR close?

Closes #2022

Rationale for this change

When running TPC-DS queries (q60-q69) with Spark 4.0 / JDK 21, the native engine panics when WrappedSender::send attempts to send data into a closed channel. This panic escalates into a JVM crash with exit code 134.

The root cause is a race condition where the producer task continues sending data while the receiver has already been closed/canceled due to task completion or cancellation. The current implementation panics on send failure instead of handling it gracefully.

Link: https://github.com/apache/auron/actions/runs/22128240337/job/63964149831?pr=2018

What changes are included in this PR?

Modified WrappedSender::send in execution_context.rs to gracefully handle channel closure:

  • Check send().await.is_err() instead of panicking
  • Log debug message with context (partition_id, task_id, session_id) for observability
  • Return early without updating metrics when channel is closed

Are there any user-facing changes?

No user-facing changes.
This is an internal fix that prevents JVM crashes when tasks are canceled or completed early.

How was this patch tested?

Exist Junit Test.

…s JVM crash.

Signed-off-by: slfan1989 <slfan1989@apache.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Native engine panic on closed channel causes JVM crash

1 participant

Comments