cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yu...@apache.org
Subject [1/6] git commit: fix get_count returns incorrect value with TTL; patch by yukim reviewed by slebresne for CASSANDRA-5099
Date Fri, 11 Jan 2013 17:05:41 GMT
fix get_count returns incorrect value with TTL; patch by yukim reviewed by slebresne for CASSANDRA-5099


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

Branch: refs/heads/cassandra-1.1
Commit: 1cbbba095a715cc69254336d34d840463b1fd46e
Parents: 3bb84e9
Author: Yuki Morishita <yukim@apache.org>
Authored: Fri Jan 11 10:48:17 2013 -0600
Committer: Yuki Morishita <yukim@apache.org>
Committed: Fri Jan 11 11:01:42 2013 -0600

----------------------------------------------------------------------
 CHANGES.txt                                        |    1 +
 .../apache/cassandra/thrift/CassandraServer.java   |    4 ++--
 2 files changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/1cbbba09/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 9712791..82f503c 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -8,6 +8,7 @@
  * nodetool repair command now prints progress (CASSANDRA-4767)
  * fix user defined compaction to run against 1.1 data directory (CASSANDRA-5118)
  * Fix CQL3 BATCH authorization caching (CASSANDRA-5145)
+ * fix get_count returns incorrect value with TTL (CASSANDRA-5099)
 
 
 1.1.8

http://git-wip-us.apache.org/repos/asf/cassandra/blob/1cbbba09/src/java/org/apache/cassandra/thrift/CassandraServer.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/thrift/CassandraServer.java b/src/java/org/apache/cassandra/thrift/CassandraServer.java
index d9965d1..4e61e9a 100644
--- a/src/java/org/apache/cassandra/thrift/CassandraServer.java
+++ b/src/java/org/apache/cassandra/thrift/CassandraServer.java
@@ -450,8 +450,8 @@ public class CassandraServer implements Cassandra.Iface
             pages++;
             // We're done if either:
             //   - We've querying the number of columns requested by the user
-            //   - The last page wasn't full
-            if (remaining == 0 || columns.size() < predicate.slice_range.count)
+            //   - last fetched page only contains the column we already fetched
+            if (remaining == 0 || ((columns.size() == 1) && (firstName.equals(predicate.slice_range.start))))
                 break;
             else
                 predicate.slice_range.start = getName(columns.get(columns.size() - 1));


Mime
View raw message