[TPU Raiden] Fix [Failure/ReceiveDisconnect]: propagate broken inbound streams to fail active receive sessions and release staging slots immediately. - #1041
Open
copybara-service[bot] wants to merge 1 commit into
Conversation
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
…d streams to fail active receive sessions and release staging slots immediately. When an inbound TCP push connection fails, resets, or suffers an I/O read error, the transport server previously logged the error but did not notify the owning delegate. Without this notification, decode receive sessions remained oblivious to the disconnect and stalled until per-transfer timeouts (30s) expired, keeping host staging buffers locked and causing Head-of-Line blocking / slot starvation for subsequent healthy transfers. This change: 1. Adds OnReceiveFailed to RawBufferTransportDelegate and BlockTransportDelegate. 2. In BlockTransport and RawBufferTransport, invokes OnReceiveFailed(uuid, status) whenever an incoming push stream fails. 3. Wires OnReceiveFailed through KVCacheManagerBase's TransferEventHooks to KVCacheManagerWithTransfer::OnReceiveFailed. 4. In KVCacheManagerWithTransfer::OnReceiveFailed, immediately finishes the active receive session with the error status, setting draining=true and releasing host staging slots back to the free pool immediately on socket disconnect. 5. Adds unit tests in block_transport_test and kv_cache_manager_with_transfer_test verifying immediate failure notification and receive session settlement. PiperOrigin-RevId: 987666213
copybara-service
Bot
force-pushed
the
test_987666213
branch
from
September 24, 2026 21:23
0dea5f5 to
02a2bd5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
[TPU Raiden] Fix [Failure/ReceiveDisconnect]: propagate broken inbound streams to fail active receive sessions and release staging slots immediately.
When an inbound TCP push connection fails, resets, or suffers an I/O read error,
the transport server previously logged the error but did not notify the owning delegate.
Without this notification, decode receive sessions remained oblivious to the disconnect
and stalled until per-transfer timeouts (30s) expired, keeping host staging buffers locked
and causing Head-of-Line blocking / slot starvation for subsequent healthy transfers.
This change:
whenever an incoming push stream fails.
KVCacheManagerWithTransfer::OnReceiveFailed.
receive session with the error status, setting draining=true and releasing
host staging slots back to the free pool immediately on socket disconnect.
verifying immediate failure notification and receive session settlement.