activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From martyntay...@apache.org
Subject [2/2] activemq-artemis git commit: ARTEMIS-1842 make sure quorum vote loops exits
Date Thu, 03 May 2018 09:22:29 GMT
ARTEMIS-1842 make sure quorum vote loops exits

The stopped flag used to stop the quorum vote loop needs to be volatile
in order to be safely published between threads.


Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/2eef0fbb
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/2eef0fbb
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/2eef0fbb

Branch: refs/heads/master
Commit: 2eef0fbb10507565d145844cb7fd83b0bea90118
Parents: 2ddaa0a
Author: Francesco Nigro <nigro.fra@gmail.com>
Authored: Wed May 2 19:44:11 2018 +0200
Committer: Martyn Taylor <mtaylor@redhat.com>
Committed: Thu May 3 10:22:09 2018 +0100

----------------------------------------------------------------------
 .../core/server/cluster/qourum/SharedNothingBackupQuorum.java      | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/2eef0fbb/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/qourum/SharedNothingBackupQuorum.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/qourum/SharedNothingBackupQuorum.java
b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/qourum/SharedNothingBackupQuorum.java
index dd1248d..035ca05 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/qourum/SharedNothingBackupQuorum.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/qourum/SharedNothingBackupQuorum.java
@@ -64,7 +64,7 @@ public class SharedNothingBackupQuorum implements Quorum, SessionFailureListener
 
    private final NetworkHealthCheck networkHealthCheck;
 
-   private boolean stopped = false;
+   private volatile boolean stopped = false;
 
    /**
     * This is a safety net in case the live sends the first {@link ReplicationLiveIsStoppingMessage}


Mime
View raw message