Daniil Kirilyuk created QPID-8781:
-------------------------------------
Summary: [Broker-J] Unacknowledged messages are not marked as
redelivered after broker restart
Key: QPID-8781
URL: https://issues.apache.org/jira/browse/QPID-8781
Project: Qpid
Issue Type: Bug
Components: Broker-J
Affects Versions: qpid-java-broker-10.1.1
Reporter: Daniil Kirilyuk
Assignee: Daniil Kirilyuk
Fix For: qpid-java-broker-10.2.0
When Broker-J recovers messages from a persistent store, it recreates their
queue entries with first-delivery metadata. A message delivered to an
application but not acknowledged before a broker failure can therefore be
delivered again with JMSRedelivered=false and JMSXDeliveryCount=1.
This hides the possibility of duplicate delivery from applications that use
these fields to decide whether additional duplicate-processing checks are
necessary.
To reproduce using Qpid JMS over AMQP 1.0:
1. Configure a persistent virtual host, for example using BDB or Derby, and
create a durable queue.
2. Publish a persistent message and receive it using a CLIENT_ACKNOWLEDGE
session, without acknowledging it.
3. Terminate the broker while the message remains unacknowledged.
4. Restart the broker using the same store.
5. Receive the recovered message through a new client connection and inspect
its redelivery metadata.
The message can arrive with JMSRedelivered=false and JMSXDeliveryCount=1. It
should indicate redelivery, with JMSRedelivered=true and JMSXDeliveryCount of
at least 2.
[Jakarta Messaging 3.1
specification|https://jakarta.ee/specifications/messaging/3.1/jakarta-messaging-spec-3.1.html]
requires redelivery indication and an incremented delivery count for
unacknowledged messages redelivered after system failure (section 9.1).
Sections 3.4.7 and 3.5.11 define these fields and permit the exact delivery
count to be lost during a failure.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]