Author: clebert.suconic(a)jboss.com
Date: 2011-08-29 20:03:18 -0400 (Mon, 29 Aug 2011)
New Revision: 11241
Modified:
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/client/impl/ClientSessionFactoryImpl.java
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/server/ServerSession.java
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java
Log:
just a few tweaks to my branch
Modified:
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/client/impl/ClientSessionFactoryImpl.java
===================================================================
---
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/client/impl/ClientSessionFactoryImpl.java 2011-08-29
21:57:04 UTC (rev 11240)
+++
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/client/impl/ClientSessionFactoryImpl.java 2011-08-30
00:03:18 UTC (rev 11241)
@@ -1297,8 +1297,6 @@
if (serverLocator.isClusterConnection())
{
-
- new Exception("Announcing node::").printStackTrace();
TransportConfiguration config =
serverLocator.getClusterTransportConfiguration();
if (ClientSessionFactoryImpl.isDebug)
{
@@ -1331,9 +1329,6 @@
ClientSessionFactoryImpl.log.debug("Announcing node " +
serverLocator.getNodeID() +
", isBackup=" + isBackup);
}
- ClientSessionFactoryImpl.log.info("YYY Announcing node " +
serverLocator.getNodeID() + ", config=" + config +
- ", backup=" + backupConfig +
- ", isBackup=" + isBackup);
channel0.send(new NodeAnnounceMessage(currentEventID, nodeID, isBackup, config,
backupConfig));
}
@@ -1462,6 +1457,7 @@
if (nodeID != null)
{
+ // TODO: calculate the time of node down
serverLocator.notifyNodeDown(System.currentTimeMillis(),
msg.getNodeID().toString());
}
@@ -1479,8 +1475,6 @@
}
else if (type == PacketImpl.CLUSTER_TOPOLOGY)
{
- log.warn("Server is sending packets from an older version. " +
- "You must update all the servers to the same version on a
cluster!");
ClusterTopologyChangeMessage topMessage =
(ClusterTopologyChangeMessage)packet;
if (topMessage.isExit())
Modified:
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/server/ServerSession.java
===================================================================
---
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/server/ServerSession.java 2011-08-29
21:57:04 UTC (rev 11240)
+++
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/server/ServerSession.java 2011-08-30
00:03:18 UTC (rev 11241)
@@ -15,12 +15,9 @@
import java.util.List;
import java.util.Set;
-import java.util.UUID;
-import java.util.concurrent.atomic.AtomicLong;
import javax.transaction.xa.Xid;
-import org.hornetq.api.core.Pair;
import org.hornetq.api.core.SimpleString;
import org.hornetq.core.message.impl.MessageInternal;
import org.hornetq.core.persistence.OperationContext;
Modified:
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java
===================================================================
---
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java 2011-08-29
21:57:04 UTC (rev 11240)
+++
branches/Branch_2_2_EAP_cluster_clean3/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java 2011-08-30
00:03:18 UTC (rev 11241)
@@ -357,7 +357,7 @@
//looks like we've failed over at some point need to inform that we
are the backup so when the current live
// goes down they failover to us
clusterManager.announceBackup();
- //Thread.sleep(configuration.getFailbackDelay());
+ Thread.sleep(configuration.getFailbackDelay());
}
nodeManager.startLiveNode();
@@ -2003,7 +2003,14 @@
public String toString()
{
- return "HornetQServerImpl::" + (identity == null ? "" :
(identity + ", "))/* + (nodeManager != null ? ("serverUUID=" +
nodeManager.getUUID()) : "")*/;
+ if (identity != null)
+ {
+ return "HornetQServerImpl::" + identity;
+ }
+ else
+ {
+ return "HornetQServerImpl::" + (nodeManager != null ?
"serverUUID=" + nodeManager.getUUID() : "");
+ }
}
// Inner classes
Show replies by date