You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by an...@apache.org on 2017/05/11 15:57:02 UTC

[1/2] activemq-artemis git commit: ARTEMIS-1154 tweak logic to support previous semantics

Repository: activemq-artemis
Updated Branches:
  refs/heads/master 02dcfe046 -> ec49c4310


ARTEMIS-1154 tweak logic to support previous semantics


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

Branch: refs/heads/master
Commit: 88e185d2b915e4827803dc7302152c6087924211
Parents: 02dcfe0
Author: Justin Bertram <jb...@apache.org>
Authored: Thu May 11 09:54:28 2017 -0500
Committer: Justin Bertram <jb...@apache.org>
Committed: Thu May 11 09:54:28 2017 -0500

----------------------------------------------------------------------
 .../cluster/qourum/SharedNothingBackupQuorum.java  | 17 +++++++++++------
 1 file changed, 11 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/88e185d2/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 a5f1d8d..81b70ad 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
@@ -108,12 +108,17 @@ public class SharedNothingBackupQuorum implements Quorum, SessionFailureListener
             signal = BACKUP_ACTIVATION.FAIL_OVER;
          }
 
-         if (networkHealthCheck != null && !networkHealthCheck.isEmpty() && networkHealthCheck.check()) {
-            // live is assumed to be down, backup fails-over
-            signal = BACKUP_ACTIVATION.FAIL_OVER;
-         } else {
-            ActiveMQServerLogger.LOGGER.serverIsolatedOnNetwork();
-            signal = BACKUP_ACTIVATION.FAILURE_REPLICATING;
+         /* use NetworkHealthCheck to determine if node is isolated
+          * if there are no addresses/urls configured then ignore and rely on quorum vote only
+          */
+         if (networkHealthCheck != null && !networkHealthCheck.isEmpty()) {
+            if (networkHealthCheck.check()) {
+               // live is assumed to be down, backup fails-over
+               signal = BACKUP_ACTIVATION.FAIL_OVER;
+            } else {
+               ActiveMQServerLogger.LOGGER.serverIsolatedOnNetwork();
+               signal = BACKUP_ACTIVATION.FAILURE_REPLICATING;
+            }
          }
       }
       latch.countDown();


[2/2] activemq-artemis git commit: This closes #1265 ARTEMIS-1154 tweak logic to support previous semantics

Posted by an...@apache.org.
This closes #1265 ARTEMIS-1154 tweak logic to support previous semantics


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

Branch: refs/heads/master
Commit: ec49c4310bde424947dfd82f1ea313059130bafe
Parents: 02dcfe0 88e185d
Author: Andy Taylor <an...@gmail.com>
Authored: Thu May 11 16:56:22 2017 +0100
Committer: Andy Taylor <an...@gmail.com>
Committed: Thu May 11 16:56:22 2017 +0100

----------------------------------------------------------------------
 .../cluster/qourum/SharedNothingBackupQuorum.java  | 17 +++++++++++------
 1 file changed, 11 insertions(+), 6 deletions(-)
----------------------------------------------------------------------