[ 
https://issues.apache.org/jira/browse/ARTEMIS-5753?focusedWorklogId=990988&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-990988
 ]

ASF GitHub Bot logged work on ARTEMIS-5753:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 10/Nov/25 16:35
            Start Date: 10/Nov/25 16:35
    Worklog Time Spent: 10m 
      Work Description: clebertsuconic commented on code in PR #6037:
URL: https://github.com/apache/activemq-artemis/pull/6037#discussion_r2511234936


##########
artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/management/SimpleManagement.java:
##########
@@ -101,8 +101,15 @@ public long getCurrentTimeMillis() throws Exception {
       return simpleManagementLong("broker", "getCurrentTimeMillis");
    }
 
-   public boolean isReplicaSync() throws Exception {
-      return simpleManagementBoolean("broker", "isReplicaSync");
+   public boolean isReplicaSync() {
+      try {
+         return simpleManagementBoolean("broker", "isReplicaSync");
+      } catch (Throwable e) {
+         // in case of a failure we return false..
+         // so the caller may keep retrying until it's true
+         logger.warn(e.getMessage(), e);
+         return false;

Review Comment:
   I don't think so in this case... 





Issue Time Tracking
-------------------

    Worklog Id:     (was: 990988)
    Time Spent: 0.5h  (was: 20m)

> Paging has the possibility on losing messages during failback in older 
> versions (before 2.33)
> ---------------------------------------------------------------------------------------------
>
>                 Key: ARTEMIS-5753
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-5753
>             Project: ActiveMQ Artemis
>          Issue Type: Bug
>    Affects Versions: 2.33.0
>            Reporter: Clebert Suconic
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 2.45.0
>
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> We recently changed the paging thread model to be single threaded, so recent 
> versions are not affected by this.
> 2.33 and before could get into a race where Pages are marked as complete and 
> the entire set of files removed, future written pages would then be marked as 
> complete and these messages wouldn't be delivered.
> This happened during failback on the reports I had seen, and on my tests.
> I couldn't reproduce this on latest versions, and that's consistent with the 
> new threading model.
> I am adding a UnitTest introducing the exact conditon that would cause the 
> loss on the latest version and still applying a defense in case it happened, 
> just to be safe.
> I am also applying some extra cleanup on Acks in case the page files are not 
> present, to prevent any possible loss.



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

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact


Reply via email to