[
https://issues.apache.org/jira/browse/PROTON-812?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14301530#comment-14301530
]
Gordon Sim commented on PROTON-812:
-----------------------------------
When a peer detaches a link, it can supply a condition that is a string code
that provides some context or reason for the detach. The correct behaviour on
receiving an attach is always to echo an attach back, but then to follow that
immediately with a detach.
So, in general, in order to distinguish between two cases of the peer detaching
a link there would need to be distinct conditions associated with the two
cases. This change allows you to determine the condition.
There is one special case, where the node the link is to be attached to doesn't
exist and is not going to be created, the appropriate response is to send back
an attach with no source or target (depending on direction of link) at all.
That is in effect a precursor to an immediate detach with not-found as the
condition.
I don't know how dispatch router will handle case 2 above. For case 1, against
qpidd, you will get a LinkException on create_receiver or create_sender, due to
the source.target respectively being null on the attach sent back by the broker.
> LinkException needs an attribute that indicates the reason for the exception.
> -----------------------------------------------------------------------------
>
> Key: PROTON-812
> URL: https://issues.apache.org/jira/browse/PROTON-812
> Project: Qpid Proton
> Issue Type: Improvement
> Affects Versions: 0.8
> Reporter: Jeff Ortel
> Assignee: Gordon Sim
> Fix For: 0.9
>
>
> LinkException needs an attribute that indicates the reason for the exception
> so that the exception can be appropriately delt with. For example: A link
> exception caused when a node does not exist would be delt with differently
> than a link exception caused by an issue in the link chain involving dispatch
> router. Having constants for the error codes would be desireable.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)