From do-not-reply at jboss.org Mon Jun 27 09:41:36 2011
Content-Type: multipart/mixed; boundary="===============4572204484057019350=="
MIME-Version: 1.0
From: do-not-reply at jboss.org
To: hornetq-commits at lists.jboss.org
Subject: [hornetq-commits] JBoss hornetq SVN: r10884 -
trunk/hornetq-core/src/main/java/org/hornetq/core/server/cluster/impl.
Date: Mon, 27 Jun 2011 09:41:35 -0400
Message-ID: <201106271341.p5RDfZ5H019677@svn01.web.mwc.hst.phx2.redhat.com>
--===============4572204484057019350==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: quoted-printable
Author: borges
Date: 2011-06-27 09:41:35 -0400 (Mon, 27 Jun 2011)
New Revision: 10884
Modified:
trunk/hornetq-core/src/main/java/org/hornetq/core/server/cluster/impl/Cl=
usterManagerImpl.java
Log:
Document parameter name swap 'confusion'
Modified: trunk/hornetq-core/src/main/java/org/hornetq/core/server/cluster/=
impl/ClusterManagerImpl.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/hornetq-core/src/main/java/org/hornetq/core/server/cluster/impl/C=
lusterManagerImpl.java 2011-06-27 13:41:00 UTC (rev 10883)
+++ trunk/hornetq-core/src/main/java/org/hornetq/core/server/cluster/impl/C=
lusterManagerImpl.java 2011-06-27 13:41:35 UTC (rev 10884)
@@ -17,12 +17,16 @@
=
import java.lang.reflect.Array;
import java.net.InetAddress;
-import java.util.*;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
import java.util.concurrent.Executor;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.ScheduledFuture;
=
-
import org.hornetq.api.core.DiscoveryGroupConfiguration;
import org.hornetq.api.core.Pair;
import org.hornetq.api.core.SimpleString;
@@ -33,7 +37,10 @@
import org.hornetq.core.client.impl.ServerLocatorInternal;
import org.hornetq.core.client.impl.Topology;
import org.hornetq.core.client.impl.TopologyMember;
-import org.hornetq.core.config.*;
+import org.hornetq.core.config.BridgeConfiguration;
+import org.hornetq.core.config.BroadcastGroupConfiguration;
+import org.hornetq.core.config.ClusterConnectionConfiguration;
+import org.hornetq.core.config.Configuration;
import org.hornetq.core.logging.Logger;
import org.hornetq.core.postoffice.Binding;
import org.hornetq.core.postoffice.PostOffice;
@@ -54,7 +61,7 @@
* A ClusterManagerImpl
*
* @author Tim Fox
- * =
+ *
* Created 18 Nov 2008 09:23:49
*
*
@@ -92,18 +99,18 @@
=
// regular client listeners to be notified of cluster topology changes.
// they correspond to regular clients using a HA ServerLocator
- private Set clientListeners =3D new Concurrent=
HashSet();
- =
+ private final Set clientListeners =3D new Conc=
urrentHashSet();
+
// cluster connections listeners to be notified of cluster topology cha=
nges
// they correspond to cluster connections on *other nodes connected to =
this one*
- private Set clusterConnectionListeners =3D new=
ConcurrentHashSet();
+ private final Set clusterConnectionListeners =
=3D new ConcurrentHashSet();
=
- private Topology topology =3D new Topology();
+ private final Topology topology =3D new Topology();
=
private volatile ServerLocatorInternal backupServerLocator;
=
private final List clusterLocators =3D new Array=
List();
- private Executor executor;
+ private final Executor executor;
=
public ClusterManagerImpl(final ExecutorFactory executorFactory,
final HornetQServer server,
@@ -173,7 +180,7 @@
{
announceNode();
}
- =
+
started =3D true;
}
=
@@ -200,7 +207,7 @@
clusterConnection.stop();
managementService.unregisterCluster(clusterConnection.getName(=
).toString());
}
- =
+
clusterConnectionListeners.clear();
clientListeners.clear();
clusterConnections.clear();
@@ -238,7 +245,7 @@
}
=
boolean removed =3D topology.removeMember(nodeID);
- =
+
if (removed)
{
=
@@ -254,6 +261,7 @@
}
}
=
+ // XXX Why is the interface's parameter 'backup' now 'last'?
public void notifyNodeUp(final String nodeID,
final Pair connectorPair,
final boolean last,
@@ -349,7 +357,7 @@
{
return topology;
}
- =
+
// backup node becomes live
public synchronized void activate()
{
@@ -496,7 +504,7 @@
{
listener.nodeUP(nodeID, member.getConnector(), false);
}
- =
+
for (ClusterTopologyListener listener : clusterConnectionListeners)
{
listener.nodeUP(nodeID, member.getConnector(), false);
@@ -720,7 +728,7 @@
managementService.unregisterBridge(name);
}
}
- =
+
private synchronized void deployClusterConnection(final ClusterConnecti=
onConfiguration config) throws Exception
{
if (config.getName() =3D=3D null)
@@ -816,7 +824,7 @@
clusterConnections.put(config.getName(), clusterConnection);
=
clusterConnection.start();
- =
+
if(backup)
{
announceBackup(config, connector);
@@ -866,7 +874,7 @@
}
catch (Exception e)
{
- log.warn("Unable to announce backup", e); =
+ log.warn("Unable to announce backup", e);
}
}
});
--===============4572204484057019350==--