Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make channel raise Connection::ClosedException #46

Merged
merged 6 commits into from
Aug 23, 2024

Conversation

spuun
Copy link
Member

@spuun spuun commented Aug 22, 2024

A Channel#basic_consume with block = true didn't raise any exception if the connection was closed by the broker, the method just returned. This because we only checked if the channel had been closed, not the connection.

This will add check that the connection hasn't been closed in every place where we checked if the channel has been closed, and if the connection has been closed a Connection::ClosedException will be raised.

I've added a few specs, but not all cases are covered.

@spuun spuun force-pushed the make-channel-raise-connection-closedexception branch from 18f686b to 881c556 Compare August 23, 2024 08:10
@spuun spuun marked this pull request as ready for review August 23, 2024 08:23
@spuun spuun force-pushed the make-channel-raise-connection-closedexception branch from ad835a0 to 281318c Compare August 23, 2024 08:46
@spuun spuun merged commit 6708526 into main Aug 23, 2024
3 checks passed
@spuun spuun deleted the make-channel-raise-connection-closedexception branch August 23, 2024 08:50
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