You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by jb...@apache.org on 2013/01/09 23:44:25 UTC
[4/6] git commit: merge from 1.1
merge from 1.1
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/94f0b856
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/94f0b856
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/94f0b856
Branch: refs/heads/trunk
Commit: 94f0b8568db62d09c1c82a2eb3da6d5a1b599c99
Parents: 1c2a69c 0d2410e
Author: Jonathan Ellis <jb...@apache.org>
Authored: Wed Jan 9 16:44:13 2013 -0600
Committer: Jonathan Ellis <jb...@apache.org>
Committed: Wed Jan 9 16:44:19 2013 -0600
----------------------------------------------------------------------
.../apache/cassandra/thrift/ThriftValidation.java | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/94f0b856/src/java/org/apache/cassandra/thrift/ThriftValidation.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/thrift/ThriftValidation.java
index 6473acd,f9733d6..c0702b2
--- a/src/java/org/apache/cassandra/thrift/ThriftValidation.java
+++ b/src/java/org/apache/cassandra/thrift/ThriftValidation.java
@@@ -460,7 -486,7 +460,7 @@@ public class ThriftValidatio
if ((range.start_key == null) == (range.start_token == null)
|| (range.end_key == null) == (range.end_token == null))
{
- throw new org.apache.cassandra.exceptions.InvalidRequestException("exactly one of {start key, end key} or {start token, end token} must be specified");
- throw new InvalidRequestException("exactly one each of {start key, start token} and {end key, end token} must be specified");
++ throw new org.apache.cassandra.exceptions.InvalidRequestException("exactly one each of {start key, start token} and {end key, end token} must be specified");
}
// (key, token) is supported (for wide-row CFRR) but not (token, key)
@@@ -475,10 -501,10 +475,10 @@@
Token endToken = p.getToken(range.end_key);
if (startToken.compareTo(endToken) > 0 && !endToken.isMinimum(p))
{
- if (p instanceof RandomPartitioner)
- throw new org.apache.cassandra.exceptions.InvalidRequestException("start key's md5 sorts after end key's md5. this is not allowed; you probably should not specify end key at all, under RandomPartitioner");
- else
+ if (p.preservesOrder())
- throw new InvalidRequestException("start key must sort before (or equal to) finish key in your partitioner!");
+ throw new org.apache.cassandra.exceptions.InvalidRequestException("start key must sort before (or equal to) finish key in your partitioner!");
+ else
- throw new InvalidRequestException("start key's md5 sorts after end key's md5. this is not allowed; you probably should not specify end key at all, under RandomPartitioner");
++ throw new org.apache.cassandra.exceptions.InvalidRequestException("start key's token sorts after end key's token. this is not allowed; you probably should not specify end key at all except with an ordered partitioner");
}
}
else if (range.end_token != null)