Skip to content

Conversation

bimmlerd
Copy link
Member

If a shared client exchange fell into the fail-safe timeout of one minute, but the handler loop (due to either an error, closing or a very delayed response) would write to the now reader-less channel, it would block all future progress of this shared client. Prevent that from happening by buffering the channel for the one message it will receive.

Fixes: 4e6b438 (shared client: add fail-safe mechanism for stuck requests.)

If a shared client exchange fell into the fail-safe timeout of one
minute, but the handler loop (due to either an error, closing or a
_very_ delayed response) would write to the now reader-less channel, it
would block all future progress of this shared client. Prevent that from
happening by buffering the channel for the one message it will receive.

Fixes: 4e6b438 (shared client: add fail-safe mechanism for stuck requests.)

Signed-off-by: David Bimmler <david.bimmler@isovalent.com>
Copy link

@marseel marseel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 😮‍💨

@aanm aanm merged commit 9e187d7 into cilium:master Oct 28, 2024
2 checks passed
bimmlerd added a commit to bimmlerd/cilium that referenced this pull request Oct 28, 2024
If a shared client exchange fell into the fail-safe timeout of one
minute, but the handler loop (due to either an error, closing or a
_very_ delayed response) would write to the now reader-less channel, it
would block all future progress of this shared client. Prevent that from
happening by buffering the channel for the one message it will receive.

The corresponding, backportable change cilium/dns is cilium/dns#15.

Signed-off-by: David Bimmler <david.bimmler@isovalent.com>
@bimmlerd bimmlerd deleted the pr/bimmlerd/fix-stuck-shared-client branch October 28, 2024 11:10
github-merge-queue bot pushed a commit to cilium/cilium that referenced this pull request Oct 29, 2024
If a shared client exchange fell into the fail-safe timeout of one
minute, but the handler loop (due to either an error, closing or a
_very_ delayed response) would write to the now reader-less channel, it
would block all future progress of this shared client. Prevent that from
happening by buffering the channel for the one message it will receive.

The corresponding, backportable change cilium/dns is cilium/dns#15.

Signed-off-by: David Bimmler <david.bimmler@isovalent.com>
joamaki pushed a commit to cilium/cilium that referenced this pull request Nov 5, 2024
[ upstream commit 392821c ]

If a shared client exchange fell into the fail-safe timeout of one
minute, but the handler loop (due to either an error, closing or a
_very_ delayed response) would write to the now reader-less channel, it
would block all future progress of this shared client. Prevent that from
happening by buffering the channel for the one message it will receive.

The corresponding, backportable change cilium/dns is cilium/dns#15.

Signed-off-by: David Bimmler <david.bimmler@isovalent.com>
Signed-off-by: Jussi Maki <jussi@isovalent.com>
github-merge-queue bot pushed a commit to cilium/cilium that referenced this pull request Nov 7, 2024
[ upstream commit 392821c ]

If a shared client exchange fell into the fail-safe timeout of one
minute, but the handler loop (due to either an error, closing or a
_very_ delayed response) would write to the now reader-less channel, it
would block all future progress of this shared client. Prevent that from
happening by buffering the channel for the one message it will receive.

The corresponding, backportable change cilium/dns is cilium/dns#15.

Signed-off-by: David Bimmler <david.bimmler@isovalent.com>
Signed-off-by: Jussi Maki <jussi@isovalent.com>
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.

3 participants