You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@activemq.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2022/06/29 23:21:00 UTC

[jira] [Commented] (ARTEMIS-3766) Mirror is not using AckReason to perform similar operations on the target mirror

    [ https://issues.apache.org/jira/browse/ARTEMIS-3766?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17560676#comment-17560676 ] 

ASF subversion and git services commented on ARTEMIS-3766:
----------------------------------------------------------

Commit 68f6d8263d8c795722805f0e4d6939e7a8b9ed48 in activemq-artemis's branch refs/heads/main from Clebert Suconic
[ https://gitbox.apache.org/repos/asf?p=activemq-artemis.git;h=68f6d8263d ]

ARTEMIS-3743 / ARTEMIS-3766 Use ACKReason on Mirror to determine target operations and fixing Delivering statistics on Mirror

I merged these two JIRAs into one as I was doing an overal check on Mirroring


> Mirror is not using AckReason to perform similar operations on the target mirror
> --------------------------------------------------------------------------------
>
>                 Key: ARTEMIS-3766
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-3766
>             Project: ActiveMQ Artemis
>          Issue Type: Bug
>    Affects Versions: 2.21.0
>            Reporter: Stephen Baker
>            Priority: Major
>             Fix For: 2.24.0
>
>
> When dual mirroring is in play there is a race condition which can result in missing or duplicate messages on the brokers.
>  
> Scenario 1:
>  # Bring up two artemis instances with broker-connection mirroring between each other. (A and B)
>  # Send a message to A with a short TTL (I used 30 seconds in my test)
>  # After the message mirrors but before it expires, pause the Mirror queue on both sides
>  # Wait for the message to expire, and the reaper thread to pick it up
>  # Observe that on both sides the message has moved to the ExpiryQueue. In the Mirror queue there are 2 messages on A (a message destined to the ExpiryQueue and an ack on the original message). On B there is a single message in the mirror, which is the message to the expiry queue.
>  # Resume the mirror, I'm not sure the order matters, but I did B and then A.
>  # Observe that on A there is a single message in the ExpiryQueue, but on B there are now 2 messages in the expiry queue.
> Scenario 2:
>  # Bring up two artemis instances with broker-connection mirroring between each other. (A and B). On A disable the reaper thread by setting `<message-expiry-scan-period>-1</message-expiry-scan-period>`
>  # Send a message to A with a short TTL
>  # Wait for the TTL to expire
>  # On B the message moves to the ExpiryQueue, on A the message ends disappears (no longer in the ExpiryQueue nor the original queue)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)