Skip to content

[core] Close spill channels when final flush fails - #11364

Open
zhangyue19921010 wants to merge 1 commit into
apache:masterfrom
zhangyue19921010:contrib/m08-spill-quota8-current-20261123
Open

zhangyue19921010 wants to merge 1 commit into
apache:masterfrom
zhangyue19921010:contrib/m08-spill-quota8-current-20261123

Conversation

@zhangyue19921010

Copy link
Copy Markdown
Contributor

Purpose

Fixes #11363.

Close the spill output channel in finally when the final compressed block write or size lookup fails. The existing path exits before channel close; a later deletion can fail because the channel is still open and hide the original error.

Clear the output state, attempt channel close, and preserve the first failure with a distinct close failure suppressed. The shared IOManager remains owned by its caller.

Tests

ChannelWriterOutputViewTest: all eight cases passed, including real-channel final-flush/size failures, distinct and shared exception identities, close-and-delete, a real external-sorter spill, and normal controls. Six cases fail on unchanged production code; two controls pass.

The scoped Maven run passed with Checkstyle, Spotless, and Enforcer enabled, and core source RAT passed. A separate JUnit run of the same eight cases corroborated the final commit. JDK 11 with Java 8 source target; failure injection uses real local channels, without a full engine job or OS disk-full experiment.

@zhangyue19921010

Copy link
Copy Markdown
Contributor Author

CI stopped in JDK setup (tar exit 2). Could you rerun the failed job?

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.

[Bug] Final spill flush failure leaves the output channel open

1 participant