cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From slebre...@apache.org
Subject [1/4] git commit: Fix Assertion errors when using empty clustering with static columns
Date Mon, 30 Jun 2014 14:48:14 GMT
Repository: cassandra
Updated Branches:
  refs/heads/trunk 02f58ff13 -> a586313ea


Fix Assertion errors when using empty clustering with static columns

patch by slebresne; reviewed by iamaleksey for CASSANDRA-7455


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

Branch: refs/heads/trunk
Commit: a9c71e4a2049070247535f5870253148619b14e8
Parents: fc9eeb9
Author: Sylvain Lebresne <sylvain@datastax.com>
Authored: Mon Jun 30 15:56:56 2014 +0200
Committer: Sylvain Lebresne <sylvain@datastax.com>
Committed: Mon Jun 30 15:56:56 2014 +0200

----------------------------------------------------------------------
 CHANGES.txt                                                      | 2 ++
 .../org/apache/cassandra/cql3/statements/ColumnGroupMap.java     | 4 ++--
 2 files changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/a9c71e4a/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index e88753f..094f2a4 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -5,6 +5,8 @@
  * Properly handle unrecognized opcodes and flags (CASSANDRA-7440)
  * (Hadoop) close CqlRecordWriter clients when finished (CASSANDRA-7459)
  * Make sure high level sstables get compacted (CASSANDRA-7414)
+ * Fix AssertionError when using empty clustering columns and static columns
+   (CASSANDRA-7455)
 
 
 2.0.9

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a9c71e4a/src/java/org/apache/cassandra/cql3/statements/ColumnGroupMap.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/cql3/statements/ColumnGroupMap.java b/src/java/org/apache/cassandra/cql3/statements/ColumnGroupMap.java
index 077a034..58428ed 100644
--- a/src/java/org/apache/cassandra/cql3/statements/ColumnGroupMap.java
+++ b/src/java/org/apache/cassandra/cql3/statements/ColumnGroupMap.java
@@ -136,13 +136,13 @@ public class ColumnGroupMap
 
             if (currentGroup == null)
             {
-                currentGroup = new ColumnGroupMap(current, composite.isStaticName(c.name()));
+                currentGroup = new ColumnGroupMap(current, CompositeType.isStaticName(c.name()));
                 currentGroup.add(current, idx, c);
                 previous = current;
                 return;
             }
 
-            if (!isSameGroup(current))
+            if ((currentGroup.isStatic && !CompositeType.isStaticName(c.name()))
|| !isSameGroup(current))
             {
                 groups.add(currentGroup);
                 // Note that we know that only the first group built can be static


Mime
View raw message