On 10/04/2019 18:18, Gordon Sim wrote:
On 10/04/2019 10:10 am, Toralf Lund wrote:
Hi,
In one of my C++ "messaging" programs I sometimes use
qpid::Messaging::Session::checkError() as a way to "rethrow" (in as
somewhat loose sense) sender or receiver exceptions that were already
caught elsewhere. I notice that the exceptions I then get are not
quite the same as the original ones. I believe that with some past
QPid versions, the exception type would actually be different. With
more recent ones, it's the same, but it looks like the type is the
same, but the error message is not there - what() returns an empty
string.
Is that the expected behaviour? Are there any other cases where there
is no error description?
What type of error is this for? TransportFailure? I would expect the
what() message to be preserved.
It's a TransportFailure
catch(const qpid::types::Exception &error) {
std::cerr << "Exception \"" << error.what() << "\", address " <<
&error
<< ", type " << typeid(error).name() << "\n";
says
Exception "", address 0x2237e80, type
N4qpid9messaging16TransportFailureE
Original message is "Failed to connect (reconnect disabled)". I provoke
that error into occurring by suspending execution (kill -STOP or
Ctrl+Z), waiting for a while, then resuming.
- Toralf
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]