Repository navigation
Conversation
serverTxRequest held the server-transaction store's write lock across serverTxCreate, and creating a transaction acquires the connection its responses will ride. When the connection the request arrived on is gone, that is a dial to the Via host, which to a peer that has gone away lasts the whole connect timeout — ten seconds under the lock every request in the layer waits on. The requests queued behind it time out at their senders, whose closed connections make them the next dials, and the server side never recovers. Seen on a P-CSCF carrying ten thousand subscribers: two of four replicas ran that convoy for two hours. The transaction is now created unlocked and inserted under the lock; a retransmission that raced its copy in first wins, and the loser terminates what it created and is received by the winner. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Author
|
Duplicate of #366, opened by mistake — same change, same tests. Closing this one. |
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.
serverTxRequestheld the transaction store's write lock acrossserverTxCreate. Creating a server transaction acquires the connection its responses will use, and when the connection the request arrived on is gone that is a dial to the Via host, which for a peer that went away lasts the whole connect timeout. Every other request in the layer waits on the lock for those ten seconds, times out at its sender, and the senders' now-closed connections make them the next dials. Seen on a proxy carrying ten thousand subscribers: two of four replicas ran that convoy for two hours, 248 goroutines parked on the lock.The transaction is now created unlocked and inserted under the lock. If a retransmission raced its copy in first, the loser terminates what it created and hands its request to the winner.
Tests:
TestTransactionLayerServerTxCreationDoesNotHoldTheStore,TestTransactionLayerRacingCopiesShareOneServerTx.🤖 Generated with Claude Code