cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r924043 - /cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/gms/Gossiper.java
Date Tue, 16 Mar 2010 23:16:56 GMT
Author: jbellis
Date: Tue Mar 16 23:16:55 2010
New Revision: 924043

URL: http://svn.apache.org/viewvc?rev=924043&view=rev
Log:
warn on gossip from wrong cluster.  patch by Brandon Williams; reviewed by jbellis for CASSANDRA-769

Modified:
    cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/gms/Gossiper.java

Modified: cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/gms/Gossiper.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/gms/Gossiper.java?rev=924043&r1=924042&r2=924043&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/gms/Gossiper.java (original)
+++ cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/gms/Gossiper.java Tue Mar
16 23:16:55 2010
@@ -891,6 +891,10 @@ public class Gossiper implements IFailur
             {
                 Gossiper.instance.join(from);
             }
+            else
+            {
+                logger_.warn("ClusterName mismatch from " + from + " " + joinMessage.clusterId_
 + "!=" + DatabaseDescriptor.getClusterName());
+            }
         }
     }
 
@@ -912,7 +916,10 @@ public class Gossiper implements IFailur
                 GossipDigestSynMessage gDigestMessage = GossipDigestSynMessage.serializer().deserialize(dis);
                 /* If the message is from a different cluster throw it away. */
                 if ( !gDigestMessage.clusterId_.equals(DatabaseDescriptor.getClusterName())
)
+                {
+                    logger_.warn("ClusterName mismatch from " + from + " " + gDigestMessage.clusterId_
 + "!=" + DatabaseDescriptor.getClusterName());
                     return;
+                }
 
                 List<GossipDigest> gDigestList = gDigestMessage.getGossipDigests();
                 /* Notify the Failure Detector */



Mime
View raw message