[
https://issues.apache.org/jira/browse/QPID-8062?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16329430#comment-16329430
]
Alex Rudyy commented on QPID-8062:
----------------------------------
Attached a patch changing {{ReceivingDestination}} to throw
{{UnroutableMessageException}}, when message cannot be accepted by
{{ReceivingDestination}}. Method {{ReceivingDestination#send()}} does not
return outcome any more. It is a responsibility of a caller to generate
{{Accepted}} outcome when method {{ReceivingDestination#send()}} does not throw
{{UnroutableMessageException}} or generate a {{Rejected}} outcome when
exception is thrown. It seems that {{Accepted}} and {{Rejected}} outcomes are
the only outcomes applicable to {{ReceivingDestination}}. The rest of outcomes
({{Modified}}, {{Released}}) cannot be really returned by
{{ReceivingDestination#send()}}. As result, there is no need to return an
outcome object from {{ReceivingDestination#send()}} : the message is either
accepted or not by {{ReceivingDestination}}. I believe that attached patch
simplifies the code and removes the some duplication from implementations of
{{ReceivingDestination}}.
> [Broker-J][AMQP 1.0] Fix handling of routing errors when target destination
> cannot route received message
> ---------------------------------------------------------------------------------------------------------
>
> Key: QPID-8062
> URL: https://issues.apache.org/jira/browse/QPID-8062
> Project: Qpid
> Issue Type: Bug
> Affects Versions: qpid-java-broker-7.0.0
> Reporter: Alex Rudyy
> Assignee: Keith Wall
> Priority: Major
> Fix For: qpid-java-broker-7.0.1
>
> Attachments:
> 0001-QPID-8062-Broker-J-AMQP-1.0-Move-responsibility-to-c.patch
>
>
> As per section "2.2.2 Routing Errors" of "Using the Anonymous Terminus for
> Message Routing Version 1.0":
> {quote}
> If the source of the link does not support the rejected outcome, or the
> message has already been settled by the sender, then the routing node MUST
> detach the link with an error. The error sent by the routing node MUST
> contain the error which would have been communicated in the detach sent on
> attempting to link directly to the address in the message’s to field.
> Additionally the info field of error MUST contain an entry with symbolic key
> delivery-tag and binary value of the delivery-tag of the message which caused
> the failure.
> {quote}
> The Broker-J does not handle the case when message is sent pre-settled and is
> rejected by the destination. We need to add the support for this behaviour.
> Additionally, if a pre-settled message is published within a transaction and
> cannot be routed by a queue/exchange/whatever then have the transactional
> resource
> logically mark the transaction as"rollback only" (i.e. failed)
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]