Skip to content

[CELEBORN-2482] Report pushes failed by push-timeout channel close as push timeout instead of connection exception - #3876

Open
afterincomparableyum wants to merge 1 commit into
apache:mainfrom
afterincomparableyum:push-timeout-close-status
Open

afterincomparableyum wants to merge 1 commit into
apache:mainfrom
afterincomparableyum:push-timeout-close-status

Conversation

@afterincomparableyum

@afterincomparableyum afterincomparableyum commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

When a push request times out and its timeout handler closes the channel (CELEBORN-2458), TransportResponseHandler now records the timeout status (PUSH_DATA_TIMEOUT_PRIMARY/REPLICA) before the close. The other pushes on that channel that fail because of the close are reported with this status instead of as connection exceptions. That covers both channelInactive and write failures on the closed channel.

Why are the changes needed?

Since CELEBORN-2458, a push timeout closes the channel. The other pushes still outstanding on it are then failed with Connection from ... closed (or Failed to send request ...), which ExceptionUtils.connectFail maps to PUSH_DATA_CONNECTION_EXCEPTION_PRIMARY/REPLICA. These collateral failures overwrite the worker's PUSH_DATA_TIMEOUT_* entry in the excluded workers, so a worker that stopped responding gets misreported as a connection failure. This also makes PushDataTimeoutTest flaky:

- celeborn spark integration test - pushdata timeout will add to pushExcludedWorkers *** FAILED ***
  PUSH_DATA_CONNECTION_EXCEPTION_PRIMARY did not equal PUSH_DATA_TIMEOUT_PRIMARY, and PUSH_DATA_CONNECTION_EXCEPTION_PRIMARY did not equal PUSH_DATA_TIMEOUT_REPLICA (PushDataTimeoutTest.scala:157)

In the failed run, a push to a worker timed out (PUSH_DATA_TIMEOUT_PRIMARY). In the same millisecond, Still have 1 requests outstanding when connection from ... is closed failed a second push on that channel, and the worker was then reported as PUSH_DATA_CONNECTION_EXCEPTION_PRIMARY.

Does this PR resolve a correctness bug?

  • Yes

Does this PR introduce any user-facing change?

  • Yes

How was this patch tested?

  • New tests in TransportResponseHandlerSuiteJ. The new push-timeout test fails without this change.
    • A push timeout that closes the channel fails the other outstanding pushes, and later write failures, with the timeout status.
    • A channel close without a push timeout still fails pushes with the connection exception.
  • TransportResponseHandlerSuiteJ (10 tests) and TransportClientFactorySuiteJ (11 tests): passed.
  • PushDataTimeoutTest with Spark 3.5: 5 tests passed.

… push timeout instead of connection exception

CELEBORN-2458 closes the channel when a push request times out. The other
pushes still outstanding on that channel are then failed by channelInactive
with "Connection from ... closed" (or by the write listener with "Failed to
send request ..."), which ExceptionUtils.connectFail maps to
PUSH_DATA_CONNECTION_EXCEPTION_PRIMARY/REPLICA. Those reports overwrite the
worker's PUSH_DATA_TIMEOUT_* entry in the excluded workers, misattributing a
worker that stopped responding as a connection failure, and make
PushDataTimeoutTest "pushdata timeout will add to pushExcludedWorkers" flaky.

Record the push timeout status before the timeout handler closes the channel
and use it for the remaining pushes failed on that channel.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant