activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rajdav...@apache.org
Subject svn commit: r378966 - /incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/BrokerService.java
Date Sun, 19 Feb 2006 22:12:40 GMT
Author: rajdavies
Date: Sun Feb 19 14:12:39 2006
New Revision: 378966

URL: http://svn.apache.org/viewcvs?rev=378966&view=rev
Log:
remove VMTransport connectors last in stop() - can prevent hanging tests

Modified:
    incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/BrokerService.java

Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/BrokerService.java
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/BrokerService.java?rev=378966&r1=378965&r2=378966&view=diff
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/BrokerService.java
(original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/BrokerService.java
Sun Feb 19 14:12:39 2006
@@ -356,9 +356,7 @@
         }
         log.info("ActiveMQ Message Broker (" + getBrokerName() + ") is shutting down");
         BrokerRegistry.getInstance().unbind(getBrokerName());
-        //remove any VMTransports connected
-        VMTransportFactory.stopped(getBrokerName());
-
+        
         removeShutdownHook();
 
         ServiceStopper stopper = new ServiceStopper();
@@ -366,12 +364,7 @@
             masterConnector.stop();
         }
 
-        for (Iterator iter = getTransportConnectors().iterator(); iter.hasNext();) {
-            
-            TransportConnector connector = (TransportConnector) iter.next();
-            stopper.stop(connector);
-        }
-
+        
         for (Iterator iter = getNetworkConnectors().iterator(); iter.hasNext();) {
             NetworkConnector connector = (NetworkConnector) iter.next();
             stopper.stop(connector);
@@ -386,6 +379,16 @@
             JmsConnector connector = (JmsConnector) iter.next();
             stopper.stop(connector);
         }
+        for (Iterator iter = getTransportConnectors().iterator(); iter.hasNext();) {
+            
+            TransportConnector connector = (TransportConnector) iter.next();
+            stopper.stop(connector);
+        }
+
+        
+        //remove any VMTransports connected
+        VMTransportFactory.stopped(getBrokerName());
+
 
 
         stopper.stop(getPersistenceAdapter());



Mime
View raw message