cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jasobr...@apache.org
Subject [7/7] cassandra git commit: Merge branch 'cassandra-2.1' into cassandra-2.2
Date Wed, 22 Jul 2015 13:04:39 GMT
Merge branch 'cassandra-2.1' into cassandra-2.2

Conflicts:
	src/java/org/apache/cassandra/gms/Gossiper.java
	src/java/org/apache/cassandra/service/StorageService.java


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/11ac9388
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/11ac9388
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/11ac9388

Branch: refs/heads/cassandra-2.2
Commit: 11ac9388782992867432fc48ca4f1587e20b7171
Parents: ee89c7e c2142e6
Author: Jason Brown <jasedbrown@gmail.com>
Authored: Wed Jul 22 06:04:11 2015 -0700
Committer: Jason Brown <jasedbrown@gmail.com>
Committed: Wed Jul 22 06:04:11 2015 -0700

----------------------------------------------------------------------
 CHANGES.txt                                     |  1 +
 src/java/org/apache/cassandra/gms/Gossiper.java | 56 ++++++++++++++------
 .../cassandra/service/StorageService.java       |  3 +-
 3 files changed, 42 insertions(+), 18 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/11ac9388/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index 3895e1f,5d142cc..0fb392a
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -14,7 -5,9 +14,8 @@@ Merged from 2.1
   * Fix clientutil jar and tests (CASSANDRA-9760)
   * (cqlsh) Allow the SSL protocol version to be specified through the
     config file or environment variables (CASSANDRA-9544)
 - * Remove repair snapshot leftover on startup (CASSANDRA-7357)
  Merged from 2.0:
+  * checkForEndpointCollision fails for legitimate collisions (CASSANDRA-9765)
   * Complete CASSANDRA-8448 fix (CASSANDRA-9519)
   * Don't include auth credentials in debug log (CASSANDRA-9682)
   * Can't transition from write survey to normal mode (CASSANDRA-9740)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/11ac9388/src/java/org/apache/cassandra/gms/Gossiper.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/gms/Gossiper.java
index e131da6,f4764ce..e61a35a
--- a/src/java/org/apache/cassandra/gms/Gossiper.java
+++ b/src/java/org/apache/cassandra/gms/Gossiper.java
@@@ -1004,25 -1042,13 +1028,21 @@@ public class Gossiper implements IFailu
              markAsShutdown(ep);
      }
  
 +    public boolean isAlive(InetAddress endpoint)
 +    {
 +        EndpointState epState = getEndpointStateForEndpoint(endpoint);
 +        if (epState == null)
 +            return false;
 +        return epState.isAlive() && !isDeadState(epState);
 +    }
 +
      public boolean isDeadState(EndpointState epState)
      {
-         String state = epState.getStatus();
-         if (state.isEmpty())
+         String status = getGossipStatus(epState);
+         if (status.isEmpty())
              return false;
-         for (String deadstate : DEAD_STATES)
-         {
-             if (state.equals(deadstate))
-                 return true;
-         }
-         return false;
+ 
+         return DEAD_STATES.contains(status);
      }
  
      public boolean isSilentShutdownState(EndpointState epState)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/11ac9388/src/java/org/apache/cassandra/service/StorageService.java
----------------------------------------------------------------------


Mime
View raw message