Search in sources :

Example 1 with Endpoint

use of org.apache.qpid.proton.engine.Endpoint in project azure-iot-sdk-java by Azure.

the class ProtonJExceptionParser method getTransportExceptionFromProtonEndpoints.

private void getTransportExceptionFromProtonEndpoints(Endpoint... endpoints) {
    for (Endpoint endpoint : endpoints) {
        if (endpoint == null) {
            continue;
        }
        ErrorCondition errorCondition = getErrorConditionFromEndpoint(endpoint);
        if (errorCondition == null || errorCondition.getCondition() == null) {
            continue;
        }
        error = errorCondition.getCondition().toString();
        if (errorCondition.getDescription() != null) {
            errorDescription = errorCondition.getDescription();
        } else {
            // log statements can assume that if error != null, errorDescription != null, too.
            errorDescription = DEFAULT_ERROR_DESCRIPTION;
        }
    }
}
Also used : Endpoint(org.apache.qpid.proton.engine.Endpoint) ErrorCondition(org.apache.qpid.proton.amqp.transport.ErrorCondition)

Aggregations

ErrorCondition (org.apache.qpid.proton.amqp.transport.ErrorCondition)1 Endpoint (org.apache.qpid.proton.engine.Endpoint)1