mirror of https://github.com/apache/activemq.git
applied patch for http://issues.apache.org/activemq/browse/AMQ-1029
git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@477570 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
878b9645ce
commit
e34cbc1b07
|
@ -1463,9 +1463,18 @@ public class BrokerService implements Service, Serializable {
|
|||
*/
|
||||
protected void startAllConnectors() throws Exception{
|
||||
if (!isSlave()){
|
||||
|
||||
ArrayList al = new ArrayList();
|
||||
|
||||
for (Iterator iter = getTransportConnectors().iterator(); iter.hasNext();) {
|
||||
TransportConnector connector = (TransportConnector) iter.next();
|
||||
startTransportConnector(connector);
|
||||
al.add(startTransportConnector(connector));
|
||||
}
|
||||
|
||||
if (al.size()>0) {
|
||||
//let's clear the transportConnectors list and replace it with the started transportConnector instances
|
||||
this.transportConnectors.clear();
|
||||
setTransportConnectors(al);
|
||||
}
|
||||
|
||||
for (Iterator iter = getNetworkConnectors().iterator(); iter.hasNext();) {
|
||||
|
@ -1495,7 +1504,7 @@ public class BrokerService implements Service, Serializable {
|
|||
}
|
||||
}
|
||||
|
||||
protected void startTransportConnector(TransportConnector connector) throws Exception {
|
||||
protected TransportConnector startTransportConnector(TransportConnector connector) throws Exception {
|
||||
connector.setBroker(getBroker());
|
||||
connector.setBrokerName(getBrokerName());
|
||||
connector.setTaskRunnerFactory(getTaskRunnerFactory());
|
||||
|
@ -1508,6 +1517,8 @@ public class BrokerService implements Service, Serializable {
|
|||
connector = registerConnectorMBean(connector);
|
||||
}
|
||||
connector.start();
|
||||
|
||||
return connector;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue