[
https://issues.apache.org/jira/browse/QPID-3481?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13103727#comment-13103727
]
Andy Goldstein commented on QPID-3481:
--------------------------------------
After talking to my developer, what we are going to do is set capacity to 0,
session.reject() all acquired messages, close the receiver (thus deleting the
queue), and close the session. This should fix our issue.
Not all of our queues are auto-delete queues, so there are times when we want
the closing of the receiver to result in the queue being deleted.
There is still a small potential for message loss in general - with a
non-auto-delete queue with delete:always, acquire a message, then close the
receiver and session. The message is lost because the DeliverRecord still
exists when the receiver is closed/queue is deleted. When the session is
closed, the DeliveryRecord goes away, restoring the message to the (deleted)
queue, and then the queue's destructor is called, but the restored message is
never sent to the alternate exchange.
> Acquired messages are not sent to alternate exchange when queue is deleted
> and receiver's session closed
> --------------------------------------------------------------------------------------------------------
>
> Key: QPID-3481
> URL: https://issues.apache.org/jira/browse/QPID-3481
> Project: Qpid
> Issue Type: Bug
> Components: C++ Broker
> Reporter: Andy Goldstein
> Attachments: QPID-3481.diff
>
>
> Currently, the broker will lose messages in the following scenario:
> 1. Client creates receiver to a queue (queue has an alternate exchange
> configured)
> 2. Client acquires message from queue
> 3. Client closes receiver (with delete:always or delete:receiver)
> 4. Client closes session
> We expect that the messages should be sent to the now-deleted queue's
> alternate exchange if/when they are released.
> Messages are not sent to the alternate exchange immediately upon closure of
> the receiver because the client still has acquired messages; this is fine,
> but when the client either releases the messages or closes the session, these
> messages should be sent to the alternate exchange.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:[email protected]