cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dbros...@apache.org
Subject git commit: Merge branch 'cassandra-1.1' into trunk
Date Wed, 17 Oct 2012 04:07:41 GMT
Updated Branches:
  refs/heads/trunk 61f5e5005 -> f5dda349b


Merge branch 'cassandra-1.1' into trunk


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

Branch: refs/heads/trunk
Commit: f5dda349b36521819d26402661e1a9e5b9f76d03
Parents: 61f5e50
Author: Dave Brosius <dbrosius@apache.org>
Authored: Wed Oct 17 00:05:26 2012 -0400
Committer: Dave Brosius <dbrosius@apache.org>
Committed: Wed Oct 17 00:05:26 2012 -0400

----------------------------------------------------------------------
 .../apache/cassandra/thrift/CassandraServer.java   |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/f5dda349/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 16b953f..337b5fe 100644
--- a/src/java/org/apache/cassandra/thrift/CassandraServer.java
+++ b/src/java/org/apache/cassandra/thrift/CassandraServer.java
@@ -931,19 +931,20 @@ public class CassandraServer implements Cassandra.Iface
 
             List<Row> rows = null;
 
-            IPartitioner p = StorageService.getPartitioner();
+            IPartitioner<?> p = StorageService.getPartitioner();
             AbstractBounds<RowPosition> bounds;
             if (range.start_key == null)
             {
-                Token.TokenFactory tokenFactory = p.getTokenFactory();
+                Token.TokenFactory<?> tokenFactory = p.getTokenFactory();
                 Token left = tokenFactory.fromString(range.start_token);
                 Token right = tokenFactory.fromString(range.end_token);
                 bounds = Range.makeRowRange(left, right, p);
             }
             else
             {
-                bounds = new Bounds<RowPosition>(RowPosition.forKey(range.start_key,
p), RowPosition.forKey(
-                        range.end_key, p));
+                RowPosition end = range.end_key == null ? p.getTokenFactory().fromString(range.end_token).maxKeyBound(p)
+                                                    : RowPosition.forKey(range.end_key, p);
+                bounds = new Bounds<RowPosition>(RowPosition.forKey(range.start_key,
p), end);
             }
             schedule(DatabaseDescriptor.getRangeRpcTimeout());
             try


Mime
View raw message