You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by cl...@apache.org on 2016/02/04 21:53:34 UTC

[1/2] activemq-artemis git commit: ARTEMIS-376 NPE during fail-back

Repository: activemq-artemis
Updated Branches:
  refs/heads/master 33b1f7275 -> de4e2cfe3


ARTEMIS-376 NPE during fail-back


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

Branch: refs/heads/master
Commit: 5a483f922a63729f4d16904c6ea4f985c9a49b41
Parents: 33b1f72
Author: jbertram <jb...@apache.org>
Authored: Thu Feb 4 14:20:02 2016 -0600
Committer: jbertram <jb...@apache.org>
Committed: Thu Feb 4 14:20:02 2016 -0600

----------------------------------------------------------------------
 .../impl/SharedNothingLiveActivation.java       | 22 ++++++++++++--------
 1 file changed, 13 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/5a483f92/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedNothingLiveActivation.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedNothingLiveActivation.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedNothingLiveActivation.java
index 299df00..76730a0 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedNothingLiveActivation.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedNothingLiveActivation.java
@@ -51,6 +51,7 @@ import org.apache.activemq.artemis.spi.core.remoting.Acceptor;
 
 import java.util.List;
 import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.ExecutorService;
 import java.util.concurrent.TimeUnit;
 
 public class SharedNothingLiveActivation extends LiveActivation {
@@ -229,17 +230,20 @@ public class SharedNothingLiveActivation extends LiveActivation {
 
       @Override
       public void connectionClosed() {
-         activeMQServer.getThreadPool().execute(new Runnable() {
-            @Override
-            public void run() {
-               synchronized (replicationLock) {
-                  if (replicationManager != null) {
-                     activeMQServer.getStorageManager().stopReplication();
-                     replicationManager = null;
+         ExecutorService executorService = activeMQServer.getThreadPool();
+         if (executorService != null) {
+            executorService.execute(new Runnable() {
+               @Override
+               public void run() {
+                  synchronized (replicationLock) {
+                     if (replicationManager != null) {
+                        activeMQServer.getStorageManager().stopReplication();
+                        replicationManager = null;
+                     }
                   }
                }
-            }
-         });
+            });
+         }
       }
    }
 


[2/2] activemq-artemis git commit: This closes #372 ARTEMIS-376 NPE on Failback

Posted by cl...@apache.org.
This closes #372 ARTEMIS-376 NPE on Failback


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

Branch: refs/heads/master
Commit: de4e2cfe3aa22967d77ca0dbca67385939cd73ba
Parents: 33b1f72 5a483f9
Author: Clebert Suconic <cl...@apache.org>
Authored: Thu Feb 4 15:53:07 2016 -0500
Committer: Clebert Suconic <cl...@apache.org>
Committed: Thu Feb 4 15:53:07 2016 -0500

----------------------------------------------------------------------
 .../impl/SharedNothingLiveActivation.java       | 22 ++++++++++++--------
 1 file changed, 13 insertions(+), 9 deletions(-)
----------------------------------------------------------------------