[rabbitmq-discuss] rabbitmq-c error list

Alan Antonuk alan.antonuk at gmail.com
Thu Jul 11 17:51:39 BST 2013


On Tue, Jul 9, 2013 at 4:17 AM, Haster <haster2004 at yandex.ru> wrote:

>
> Is there some document that represent full list of errors that could be
> returned by library?
>
> I'm currently working on the API documentation for this.  So the short
answer is not yet.

That said there are places you can look that might help you:

For functions that return an int (or amqp_rpc_reply_t with reply_type set
to AMQP_RESPONSE_LIBRARY_EXCEPTION), the value will be of the set defined
in amqp_status_enum.

Given the different platforms that rabbitmq-c its hard to describe all the
things that can go wrong without duplicating all the POSIX error codes.  In
certain cases (e.g., when you get an AMQP_STATUS_SOCKET_ERROR) it might be
useful to examine errno or WSAGetLastError() to see what went wrong.
Generally speaking though, if the library gets a socket error it doesn't
understand, it assumes that the network socket is dead.

As for errors from the broker, you can find a list on lines 55-72 of
amqp_framing.h, usually when you get one of these you also get a string
describing what went wrong in addition to the error code.

HTH
-Alan
--
View this message in context:
http://rabbitmq.1065348.n5.nabble.com/rabbitmq-c-error-list-tp27924.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
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20130711/0478aa22/attachment.htm>


More information about the rabbitmq-discuss mailing list