iande / onstomp

A STOMP messaging client library for Ruby
http://mathish.com/projects/onstomp.html
Other
23 stars 11 forks source link

Failover connections may hang on `disconnect` #7

Closed iande closed 13 years ago

iande commented 13 years ago

If disconnect is called on a failover connection that is currently re-connecting, the call will hang until the connection is re-established.

This is just fine (and the expected behavior) when the connection is supposed to retry indefinitely (retry_attempts = 0). However, the same behavior is seen when retry_attempts is finite, and that's no good. In that scenario, once we have exceeded the retry attempt limit, we should bail on the disconnect process (unflushed buffers and all)