On 05/11/2011 12:55 PM, Ilyushonak Barys wrote:
Greetings.
Could you please help me to answer on the following question: how can I handle
exceptions while synchronous send?
The docs says:
If the connection fails and is transparently reconnected (see Section 2.10,
"Connection Options" for details on how to control this feature), the unsettled
messages for each sender over that connection will be re-transmitted.
http://qpid.apache.org/books/0.10/Programming-In-Apache-Qpid/html/ch02s05.html
But: what is happened if the connection do not reconnect? How can I handle such
error?
You can control the reconnection via the various related connection
settings (reconnect, reconnect_timeout etc).
If reconnection is disabled, or unsuccessful, loss of a connection is
signalled by throwing qpid::messaging::TransportFailure which you can
then catch and handle appropriately.
I would like log it in the file.
Loss of connection is already logged on the client side.
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:users-subscr...@qpid.apache.org