cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject [19/21] git commit: Merge branch 'cassandra-1.1.0' into cassandra-1.1
Date Wed, 11 Apr 2012 18:26:43 GMT
Merge branch 'cassandra-1.1.0' into cassandra-1.1


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

Branch: refs/heads/trunk
Commit: de80c6c6d1d0ff11837bb1f3467b2902c5b841ff
Parents: 6564b33 d49113f
Author: Sylvain Lebresne <sylvain@datastax.com>
Authored: Wed Apr 11 17:23:54 2012 +0200
Committer: Sylvain Lebresne <sylvain@datastax.com>
Committed: Wed Apr 11 17:23:54 2012 +0200

----------------------------------------------------------------------
 CHANGES.txt                                        |    2 +
 .../cassandra/cql3/statements/SelectStatement.java |   64 +++++++++--
 .../org/apache/cassandra/db/ColumnFamilyStore.java |   10 +-
 .../org/apache/cassandra/db/RangeSliceCommand.java |   23 +++--
 .../apache/cassandra/db/filter/ExtendedFilter.java |   30 ++++--
 .../cassandra/db/filter/SliceQueryFilter.java      |    3 +-
 .../cassandra/db/index/keys/KeysSearcher.java      |    2 +-
 .../cassandra/service/RangeSliceVerbHandler.java   |    2 +-
 .../org/apache/cassandra/service/StorageProxy.java |    3 +-
 .../apache/cassandra/thrift/CassandraServer.java   |    2 +-
 .../apache/cassandra/db/ColumnFamilyStoreTest.java |   92 +++++++++++++--
 11 files changed, 186 insertions(+), 47 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/de80c6c6/CHANGES.txt
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/de80c6c6/src/java/org/apache/cassandra/cql3/statements/SelectStatement.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/cql3/statements/SelectStatement.java
index b0d067c,0485857..b7c12dd
--- a/src/java/org/apache/cassandra/cql3/statements/SelectStatement.java
+++ b/src/java/org/apache/cassandra/cql3/statements/SelectStatement.java
@@@ -600,11 -604,22 +605,22 @@@ public class SelectStatement implement
                      if (c.isMarkedForDelete())
                          continue;
  
 -                    thriftColumns = new ArrayList<Column>();
 +                    thriftColumns = new ArrayList<Column>(selection.size());
  
-                     ByteBuffer[] components = cfDef.isComposite
-                                             ? ((CompositeType)cfDef.cfm.comparator).split(c.name())
-                                             : null;
+                     ByteBuffer[] components = null;
+ 
+                     if (cfDef.isComposite)
+                     {
+                         components = ((CompositeType)cfDef.cfm.comparator).split(c.name());
+                     }
+                     else if (sliceRestriction != null)
+                     {
+                         // For dynamic CF, the column could be out of the requested bounds,
filter here
+                         if (!sliceRestriction.isInclusive(Bound.START) && c.name().equals(sliceRestriction.bound(Bound.START).getByteBuffer(cfDef.cfm.comparator,
variables)))
+                             continue;
+                         if (!sliceRestriction.isInclusive(Bound.END) && c.name().equals(sliceRestriction.bound(Bound.END).getByteBuffer(cfDef.cfm.comparator,
variables)))
+                             continue;
+                     }
  
                      // Respect selection order
                      for (Pair<CFDefinition.Name, ColumnIdentifier> p : selection)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/de80c6c6/src/java/org/apache/cassandra/db/ColumnFamilyStore.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/de80c6c6/src/java/org/apache/cassandra/service/RangeSliceVerbHandler.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/de80c6c6/src/java/org/apache/cassandra/service/StorageProxy.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/de80c6c6/src/java/org/apache/cassandra/thrift/CassandraServer.java
----------------------------------------------------------------------


Mime
View raw message