Dieser Inhalt ist in der von Ihnen ausgewählten Sprache nicht verfügbar.
Chapter 10. The Qpid Messaging API
10.1. Handling Exceptions Link kopierenLink in die Zwischenablage kopiert!
Link kopierenLink in die Zwischenablage kopiert!
10.1.1. Messaging Exceptions Reference Link kopierenLink in die Zwischenablage kopiert!
Link kopierenLink in die Zwischenablage kopiert!
In the asynchronous and decoupled environment of a messaging application, exceptions are thrown for both local error conditions and error conditions or failures that occur remotely. Developing a robust application requires that you anticipate and handle a wide range of possible exceptions, some of which are not immediately obvious from the context of the method itself.
10.1.2. C++ Messaging Exceptions Class Hierarchy Link kopierenLink in die Zwischenablage kopiert!
Link kopierenLink in die Zwischenablage kopiert!
The following are the exceptions thrown by the C++ API, and the circumstances under which they are thrown. The source code for the exceptions can be viewed in the Apache Qpid svn repository.
- MessagingException
- The base class for Messaging exceptions.
- InvalidOptionString : public MessagingException
- Thrown when the syntax of the option string used to configure a connection is not valid.
- KeyError : public MessagingException
- Thrown to indicate a failed lookup of some local object. For example when attempting to retrieve a session, sender or receiver by name.
- LinkError : public MessagingException
- Base class for exceptions thrown to indicate a failed lookup of some local object.
- AddressError : public LinkError
- Thrown to indicate a failed lookup of some local object. For example when attempting to retrieve a session, sender or receiver by name.
- ResolutionError : public AddressError
- Thrown when a syntactically correct address cannot be resolved or used.
- AssertionFailed : public ResolutionError
- Thrown when creating a sender or receiver for an address for which some asserted property of the node is not matched.
- NotFound : public ResolutionError
- Thrown on attempts to create a sender or receiver to a non-existent node.
- MalformedAddress : public AddressError
- Thrown when an address string with invalid syntax is used.
- ReceiverError : public LinkError
- FetchError : public ReceiverError
- NoMessageAvailable : public FetchError
- Thrown by Receiver::fetch(), Receiver::get() and Session::nextReceiver() to indicate that there no message was available before the timeout specified.
- SenderError : public LinkError
- SendError : public SenderError
- TargetCapacityExceeded : public SendError
- Thrown to indicate that the sender attempted to send a message that would result in the target node on the peer exceeding a preconfigured capacity.
- SessionError : public MessagingException
- TransactionError : public SessionError
- TransactionAborted : public TransactionError
- Thrown on Session::commit() if reconnection results in the transaction being automatically aborted.
- TransactionUnknown : public TransactionError
- The outcome of the transaction on the broker (commit or roll-back) is not known. This occurs when the connection fails after the commit was sent, but before a response is received.
- UnauthorizedAccess : public SessionError
- Thrown to indicate that the application attempted to do something for which it was not authorized by its peer.
- UnauthorizedAccess : public SessionError
- ConnectionError : public MessagingException
- TransportFailure : public MessagingException
- Thrown to indicate loss of underlying connection. When auto-reconnect is used this will be caught by the library and used to trigger reconnection attempts. If reconnection fails (according to whatever settings have been configured), then an instance of this class will be thrown to signal that.
10.1.3. Connection Exceptions Link kopierenLink in die Zwischenablage kopiert!
Link kopierenLink in die Zwischenablage kopiert!
Note: Unless fully qualified, all exceptions listed are in the
qpid::messaging namespace.
- Connection::Connection(const std::string&, const qpid::types::Variant::Map&)
MessagingExceptionif any of the options in the supplied map are not recognised.qpid::types::InvalidConversionif any of the option values are of the wrong type.- Connection::Connection(const std::string& url, const std::string& options)
MessagingExceptionif any of the options in the supplied map are not recognised.qpid::types::InvalidConversionif any of the option values are of the wrong type.InvalidOptionStringif the format of the option string is invalid.- Connection::setOption(const std::string& name, const qpid::types::Variant& value)
MessagingExceptionif the named option is not recognised.qpid::types::InvalidConversionif the option value is of the wrong type.- Connection::open()
qpid::Url::Invalidif the url is not valid (this may be the url supplied on construction or any of the reconnect_urls supplied via options).TransportFailureif a connection could not be established.ConnectionErrorfor any other failure, including where the broker sends a connection.close control before the AMQP 0-10 defined connection handshake completes.qpid::types::InvalidConversionif the broker sends an improperly encoded value for the 'known-host' field of theconnection.open-ok controlas defined by AMQP 0-10 specification.- Connection::isOpen()
- Does not throw exceptions.
- Connection::close()
TargetCapacityExceededif any of the sessions established for the connection have attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif any of the sessions established for the connection have attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends a connection.close control (i.e. if broker initiates closing of an active connection just before the client does).MessagingExceptionif the broker to which the client is connected sends a session.detached control (i.e. if broker initiates closing of an active session while the close is in progress).TransportFailureif a connection was lost while trying to perform the close 'handshake' with the broker.- Connection::createTransactionalSession(const std::string& name)
SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected which could happen on enabling transactions for the session (e.g. if the broker in question did not support transactions).ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends a session.detached control (i.e. if broker initiates closing of the session before it becomes active).TransportFailureif the connection was lost (and if automatic reconnect is enabled could not be re-established).qpid::Url::Invalidif reconnect is enabled and a url in thereconnect_urlsoption list is invalid.qpid::types::InvalidConversionif the broker were to send an improperly encoded value for the 'known-host' field of theconnection.open-okcontrol as defined by AMQP 0-10 specification.- Connection::createSession(const std::string&)
ConnectionErrorif the broker to which the client is connected sends a connection.close control (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of the session before it becomes active).TransportFailureif the connection was lost (and if automatic reconnect is enabled could not be re-established).qpid::Url::Invalidif reconnect is enabled and a url in thereconnect_urlsoption list is invalid.qpid::types::InvalidConversionif the broker were to send an improperly encoded value for the 'known-host' field of the connection.open-ok control as defined by AMQP 0-10 specification.- Connection::getSession(const std::string&)
KeyErrorif no session for the specified name exists.- Connection::getAuthenticatedUsername()
- Does not throw any exception.
10.1.4. Session Exceptions Link kopierenLink in die Zwischenablage kopiert!
Link kopierenLink in die Zwischenablage kopiert!
Note: Unless fully qualified, all exceptions listed are in the
qpid::messaging namespace.
- Session::close()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::commit()
TransactionAbortedif the original AMQP 0-10 session is lost, e.g. due to failover, forcing an automatic rollback.TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends a session.detached control (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::rollback()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::acknowledge(bool)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::acknowledge(Message&, bool)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::acknowledgeUpTo(Message&, bool)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::reject(Message&)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.ThrowsSessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::release(Message&)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailure if a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::sync(bool)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::getReceivable()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::getUnsettledAcks()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailure if a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::nextReceiver(Receiver&, Duration)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends a session.detached control (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::nextReceiver(Duration)
Receiver::NoMessageAvailableif no message became available in time.TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.ThrowsSessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::createSender(const Address&)
ResolutionErrorif there is an error in resolving the address.TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends a session.detached control (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::createSender(const std::string&)
ResolutionErrorif there is an error in resolving the address.MalformedAddressif the syntax of the address string is not valid.TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::createReceiver(const Address&)
ResolutionErrorif there is an error in resolving the address.TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends a connection.close control (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends a session.detached control (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::createReceiver(const std::string&)
ResolutionErrorif there is an error in resolving the address.MalformedAddressif the syntax of the address string is not valid.TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Session::getSender(const std::string&)
KeyErrorif there is no sender for the specified name.- Session::getReceiver(const std::string&)
- KeyError if there is no receiver for the specified name.
- Session::checkError()
qpid::messaging::SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.qpid::messaging::ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).qpid::messaging::MessagingExceptionif the broker to which the client is connected sends a session.detached control (i.e. if broker initiates closing of an active session).- Session::getConnection()
- Does not throw exceptions.
- Session::hasError()
- Does not throw exceptions.
10.1.5. Sender Exceptions Link kopierenLink in die Zwischenablage kopiert!
Link kopierenLink in die Zwischenablage kopiert!
Note: Unless fully qualified, all exceptions listed are in the
qpid::messaging namespace.
- Sender::send(const Message& message, bool)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends a session.detached control (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Sender::close()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Sender::setCapacity(uint32_t)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Sender::getUnsettled()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Sender::getAvailable()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Sender::getCapacity()
- Does not throw exceptions.
- Sender::getName()
- Does not throw exceptions.
- Sender::getSession()
- Does not throw exceptions.
10.1.6. Receiver Exceptions Link kopierenLink in die Zwischenablage kopiert!
Link kopierenLink in die Zwischenablage kopiert!
Note: Unless fully qualified, all exceptions listed are in the
qpid::messaging namespace.
- Receiver::get(Message& message, Duration timeout=Duration::FOREVER)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Receiver::Message get(Duration timeout=Duration::FOREVER)
NoMessageAvailableif there is no message to give after waiting for the specified timeout, or if the Receiver is closed, in which caseisClose()will be true.TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Receiver::fetch(Message& message, Duration timeout=Duration::FOREVER)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif an execution.exception command, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Receiver::fetch(Duration timeout=Duration::FOREVER)
NoMessageAvailableif there is no message to give after waiting for the specified timeout, or if the Receiver is closed, in which caseisClose()will be true.TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Receiver::setCapacity(uint32_t)
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Receiver::getAvailable()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Receiver::getUnsettled()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Receiver::close()
TargetCapacityExceededif the session has attempted to send a message that would result in a queue exceeding configured limits.UnauthorizedAccessif the session has attempted to perform an operation for which it has not been granted permission.SessionErrorif anexecution.exceptioncommand, as defined in AMQP 0-10, is received from the broker to which the client is connected.ConnectionErrorif the broker to which the client is connected sends aconnection.closecontrol (i.e. if broker initiates closing of an active connection).MessagingExceptionif the broker to which the client is connected sends asession.detachedcontrol (i.e. if broker initiates closing of an active session).TransportFailureif a connection was lost (and if automatic reconnect is enabled could not be re-established).- Receiver::isClosed()
- Does not throw exceptions.
- Receiver::getCapacity()
- Does not throw exceptions.
- Receiver::getName()
- Does not throw exceptions.
- Receiver::getSession()
- Does not throw exceptions.