[rabbitmq-discuss] rabbitmq-c APIs hanging during network down
Alan Antonuk
alan.antonuk at gmail.com
Mon Mar 17 15:05:32 GMT 2014
On Mon, Mar 17, 2014 at 3:45 AM, Lothe Shashank <
Shashank.Lothe at techmahindra.com> wrote:
> Hi Alan,
>
> Thanks for your reply. As expected by you these kind of APIs must be
> hanging in other amqp clients as well. I have tested php APIs using
> php-amqp library and noticed the same hanging behaviour.
>
php-amqp is a wrapper around the rabbitmq-c library, and thus not really a
good comparison. You should try it with the Java or .NET clients.
>
> What could be the possible way out for these situations? Issue is raised
> in github for tracking.
>
Enable heartbeats on the client. You can do this by passing a value greater
than 0 to amqp_login(). A default used by the Java client is 600 second, or
10 minutes. It can be set lower than this if necessary. Note that
rabbitmq-c only has partial support for heartbeats: it has nothing in the
background servicing heartbeat events, so it is necessary to have your code
call into the library (or be blocked on a call into the library) more
frequently than the heartbeat interval specified.
More information about heartbeats can be found:
https://www.rabbitmq.com/reliability.html#connection-failures
>
> regards,
> Shashank
>
> ------------------------------
>
> DISCLAIMER:
> This email (including any attachments) is intended for the sole use of the
> intended recipient/s and may contain material that is CONFIDENTIAL AND
> PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying or
> distribution or forwarding of any or all of the contents in this message is
> STRICTLY PROHIBITED. If you are not the intended recipient, please contact
> the sender by email and delete all copies; your cooperation in this regard
> is appreciated.
>
> _______________________________________________
> 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/20140317/a88ee0d8/attachment.html>
More information about the rabbitmq-discuss
mailing list