[rabbitmq-discuss] Handle Stale Connections on Clients

cogitate monish.unni at gmail.com
Wed Jul 11 19:16:08 BST 2012


Jerry Kuch-2 wrote
> 
> Hi, Monish:
> 
> If you're using the naked Java client, you'll have to implement your own
> reconnection logic.  If you're using Spring AMQP there's some helper code
> that wraps your connections with some retry logic for you.
> 
> Best regards,
> Jerry
> 
thanks much Jerry for such a prompt reply. I would love to re-use
spring-amqp and use the wrapped connection( it seems CachedConnectionFactory
+ SimpleListenerContainer ). 
what i am wondering for a simple amqp client that simply wants to re-connect
when a broker shutsdown, is there any way i can re-initialize all my
reply-queues( i have uuids associated with them), channels (wrapped channel
objects associated with connections) without having to re-write the code
with spring-amqp?

sorry to be presume that you would know the answer to this.....but a simple
logic/example would be great of how to go about it. 
the spring-amqp project seems to be quite complicated as it seems to have
logic for transactions ( also it's not entirely clear to me if i need to
write a listener container or just register a shutdownlistener etc).

thanks and regards,
-monish



--
View this message in context: http://rabbitmq.1065348.n5.nabble.com/Handle-Stale-Connections-on-Clients-tp20687p20721.html
Sent from the RabbitMQ mailing list archive at Nabble.com.


More information about the rabbitmq-discuss mailing list