Skip to content
This repository has been archived by the owner on Sep 11, 2022. It is now read-only.

Emit more specific error than [amqp] Detected TCP connection failure #222

Closed
nhooey opened this issue Apr 2, 2016 · 5 comments
Closed

Comments

@nhooey
Copy link
Contributor

nhooey commented Apr 2, 2016

This line in lib/amqp/session.rb emits [amqp] Detected TCP connection failure during the following conditions, which the comment lists:

  • We close TCP connection down
  • Our peer closes TCP connection down
  • There is a network connection issue
  • Initial TCP connection fails

Which is a lot of conditions to summarize in the word "failure".

The error should be specific so someone has a hope of troubleshooting the connection error.

@nhooey
Copy link
Contributor Author

nhooey commented Apr 2, 2016

Awesome, thanks @michaelklishin! When can you cut a new release?

I'd like to get this in to Sensu as soon as possible.

@michaelklishin
Copy link
Member

In the next few days.

@michaelklishin
Copy link
Member

@nhooey I've released 1.5.3 (depends on amq-protocol 1.9.x, supports Ruby 1.9) and 1.6.0 (depends on amq-protocol 2.0.x, supports Ruby 2.0+).

In general, I'd highly recommend Sensu to switch to Bunny. amqp gem is not being actively maintained.

@nhooey
Copy link
Contributor Author

nhooey commented Apr 4, 2016

@portertech What do you think about cutting a new release of Sensu using this version, and then switching to Bunny?

@nhooey
Copy link
Contributor Author

nhooey commented Apr 4, 2016

Thanks for releasing his on short notice, @michaelklishin.

jsonn pushed a commit to jsonn/pkgsrc that referenced this issue Oct 17, 2016
## Changes Between 1.5.x and 1.6.0 (Apr 4th, 2016)

### amq-protocol Update

Minimum `amq-protocol` version is now `2.0.1`.

### Provide More Details in TCP Connection Failure Exception

Contributed by Neil Hooey.

GH issue: [#222](ruby-amqp/amqp#222).


### Ensures frameset is cleared after an unhandled exception

Ensures frameset is cleared after an unhandled exception.
This avoids confusing exceptions such as

```
undefined method `method_class' for #<AMQ::Protocol::BodyFrame:0x0000001e8a60b0>
```

Contributed by Michael Lutsiuk.

GH issue: [#218](ruby-amqp/amqp#218)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants