cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From slebre...@apache.org
Subject [1/4] cassandra git commit: Ensure unique timestamp locally for paxos
Date Mon, 29 Jun 2015 07:32:02 GMT
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.2 02a7c3429 -> 75e85b961


Ensure unique timestamp locally for paxos

patch by stefania; reviewed by slebresne for CASSANDRA-9649


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

Branch: refs/heads/cassandra-2.2
Commit: 0bdf92350bcc9e21373da81ca0c5a1c7d77ec122
Parents: 353d4a0
Author: Stefania Alborghetti <stefania.alborghetti@datastax.com>
Authored: Fri Jun 26 10:15:15 2015 +0800
Committer: Sylvain Lebresne <sylvain@datastax.com>
Committed: Mon Jun 29 09:18:11 2015 +0200

----------------------------------------------------------------------
 CHANGES.txt                                             | 1 +
 src/java/org/apache/cassandra/service/StorageProxy.java | 5 +----
 2 files changed, 2 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/0bdf9235/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 6a137a3..2a69292 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.0.17
+ * Avoid ballot clash in Paxos (CASSANDRA-9649)
  * Improve trace messages for RR (CASSANDRA-9479)
  * Fix suboptimal secondary index selection when restricted
    clustering column is also indexed (CASSANDRA-9631)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/0bdf9235/src/java/org/apache/cassandra/service/StorageProxy.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/service/StorageProxy.java b/src/java/org/apache/cassandra/service/StorageProxy.java
index aef59cf..dff4a3b 100644
--- a/src/java/org/apache/cassandra/service/StorageProxy.java
+++ b/src/java/org/apache/cassandra/service/StorageProxy.java
@@ -346,10 +346,7 @@ public class StorageProxy implements StorageProxyMBean
         int contentions = 0;
         while (System.nanoTime() - start < timeout)
         {
-            long ballotMillis = summary == null
-                              ? System.currentTimeMillis()
-                              : Math.max(System.currentTimeMillis(), 1 + UUIDGen.unixTimestamp(summary.mostRecentInProgressCommit.ballot));
-            UUID ballot = UUIDGen.getTimeUUID(ballotMillis);
+            UUID ballot = UUIDGen.getTimeUUID();
 
             // prepare
             Tracing.trace("Preparing {}", ballot);


Mime
View raw message