Skip to content

Closing an AutoRecoveringConnection does not stop it from continuing recovery forever #294

@LoungeFlyZ

Description

@LoungeFlyZ

Once an AutoRecoveringConnection connection enters auto recovery and trying to recover the connection will continue to do try forever even if the connection is manually closed.

I am not super familiar with the code, but believe the issue lays in the RecoverConnectionDelegate method that enters a while loop and fails to check if the connection has been manually closed via the manuallyClosed variable.

The order for a repro is:

  1. Create and Open auto recovering connection
  2. Sever the network connection between the client and rabbit server. The connection will start attempting auto-recovery.
  3. Call .Close() and/or .Dispose() on the connection
  4. Observe that the connection continues to try and auto-recover ... forever.

I would have expected that the connection would have given up trying to reconnect after it was closed, but i might be missing some subtle issue here that i am not aware of.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions