[rabbitmq-discuss] rabbitmq-c and network problems

Alan Antonuk alan.antonuk at gmail.com
Mon Aug 19 16:33:42 BST 2013


The library will return a library error of AMQP_STATUS_CONNECTION_CLOSED if
the underling connection to the broker has been severed.

As of rabbitmq-c v0.4.0 the library will send and receive heartbeats when
doing long-running calls into the library (e.g., calling
amqp_consume_message()) after they've been enabled by specifying a non-zero
heartbeat parameter in amqp_login(). Note that if a heartbeat timeout
occurs a library error of AMQP_STATUS_HEARTBEAT_TIMEOUT will be returned.



On Mon, Aug 19, 2013 at 2:23 AM, Tim Watson <watson.timothy at gmail.com>wrote:

> What you want to do is turn on AMQP heartbeats. IIRC the c client requires
> that you manage the send/recv of these by hand though.
>
> On 19 Aug 2013, at 09:32, Haster <haster2004 at yandex.ru> wrote:
>
> > Hi there!
> > Does rabbitmq-c library have any method to check correctness of
> connection?
> >
> > For example I call basic.consume and start reading loop from Server...
> And
> > server fall down, or network cord was cut by something... As I
> understand I
> > won't be  give noticed about this situations... (my loop is constructed
> on
> > waiting socket in select function)?
> >
> > So is it any way to know about such problems?
> >
> >
> >
> > --
> > View this message in context:
> http://rabbitmq.1065348.n5.nabble.com/rabbitmq-c-and-network-problems-tp28910.html
> > Sent from the RabbitMQ mailing list archive at Nabble.com.
> > _______________________________________________
> > rabbitmq-discuss mailing list
> > rabbitmq-discuss at lists.rabbitmq.com
> > https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com
> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20130819/47348c65/attachment.htm>


More information about the rabbitmq-discuss mailing list