You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by al...@apache.org on 2015/05/15 16:33:44 UTC

[1/3] cassandra git commit: Push correct protocol notification for DROP INDEX

Repository: cassandra
Updated Branches:
  refs/heads/trunk a16c4fe0a -> e1e30fc5e


Push correct protocol notification for DROP INDEX

patch by Carl Yeksigian; reviewed by Sam Tunnicliffe for CASSANDRA-9310


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

Branch: refs/heads/trunk
Commit: b2a2d46352d2dcd57cef968a8cd4a2189bea32ce
Parents: f4ec535
Author: Carl Yeksigian <ca...@apache.org>
Authored: Tue May 12 18:13:11 2015 -0400
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Fri May 15 17:20:34 2015 +0300

----------------------------------------------------------------------
 CHANGES.txt                                     |  2 ++
 .../cql3/statements/DropIndexStatement.java     | 24 ++++++++++++++------
 2 files changed, 19 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/b2a2d463/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index cee28bc..c3e84db 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,6 +1,8 @@
 2.0.16:
+ * Push correct protocol notification for DROP INDEX (CASSANDRA-9310)
  * token-generator - generated tokens too long (CASSANDRA-9300)
 
+
 2.0.15:
  * Fix counting of tombstones for TombstoneOverwhelmingException (CASSANDRA-9299)
  * Fix ReconnectableSnitch reconnecting to peers during upgrade (CASSANDRA-6702)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/b2a2d463/src/java/org/apache/cassandra/cql3/statements/DropIndexStatement.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/cql3/statements/DropIndexStatement.java b/src/java/org/apache/cassandra/cql3/statements/DropIndexStatement.java
index b2e8dde..c421c09 100644
--- a/src/java/org/apache/cassandra/cql3/statements/DropIndexStatement.java
+++ b/src/java/org/apache/cassandra/cql3/statements/DropIndexStatement.java
@@ -33,6 +33,9 @@ public class DropIndexStatement extends SchemaAlteringStatement
     public final String indexName;
     public final boolean ifExists;
 
+    // initialized in announceMigration()
+    private String indexedCF;
+
     public DropIndexStatement(String indexName, boolean ifExists)
     {
         super(new CFName());
@@ -40,14 +43,20 @@ public class DropIndexStatement extends SchemaAlteringStatement
         this.ifExists = ifExists;
     }
 
-    // We don't override CFStatement#columnFamily as this'd change the
-    // protocol for returned events when we drop an index. We need it
-    // to return null so that SchemaMigrations remain a keyspace,
-    // rather than table, level event (see SchemaAlteringStatement#execute).
-    public String getColumnFamily() throws InvalidRequestException
+    public String columnFamily()
     {
-        CFMetaData cfm = findIndexedCF();
-        return cfm == null ? null : cfm.cfName;
+        if (indexedCF != null)
+            return indexedCF;
+
+        try
+        {
+            CFMetaData cfm = findIndexedCF();
+            return cfm == null ? null : cfm.cfName;
+        }
+        catch (InvalidRequestException ire)
+        {
+            throw new RuntimeException(ire);
+        }
     }
 
     public void checkAccess(ClientState state) throws UnauthorizedException, InvalidRequestException
@@ -77,6 +86,7 @@ public class DropIndexStatement extends SchemaAlteringStatement
             return false;
 
         CFMetaData updatedCfm = updateCFMetadata(cfm);
+        indexedCF = updatedCfm.cfName;
         MigrationManager.announceColumnFamilyUpdate(updatedCfm, false);
         return true;
     }


[2/3] cassandra git commit: Merge branch 'cassandra-2.0' into cassandra-2.1

Posted by al...@apache.org.
Merge branch 'cassandra-2.0' into cassandra-2.1


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

Branch: refs/heads/trunk
Commit: 054f0a1580fb68a1e2ed0a921a0daf82806fad8a
Parents: 6544fb7 b2a2d46
Author: Aleksey Yeschenko <al...@apache.org>
Authored: Fri May 15 17:31:39 2015 +0300
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Fri May 15 17:31:39 2015 +0300

----------------------------------------------------------------------
 CHANGES.txt                                     |  1 +
 .../cql3/statements/DropIndexStatement.java     | 27 ++++++++++----------
 2 files changed, 14 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/054f0a15/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index 651f49a,c3e84db..fa050cd
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,30 -1,9 +1,31 @@@
 -2.0.16:
 +2.1.6
 + * Warn on misuse of unlogged batches (CASSANDRA-9282)
 + * Failure detector detects and ignores local pauses (CASSANDRA-9183)
 + * Add utility class to support for rate limiting a given log statement (CASSANDRA-9029)
 + * Add missing consistency levels to cassandra-stess (CASSANDRA-9361)
 + * Fix commitlog getCompletedTasks to not increment (CASSANDRA-9339)
 + * Fix for harmless exceptions logged as ERROR (CASSANDRA-8564)
 + * Delete processed sstables in sstablesplit/sstableupgrade (CASSANDRA-8606)
 + * Improve sstable exclusion from partition tombstones (CASSANDRA-9298)
 + * Validate the indexed column rather than the cell's contents for 2i (CASSANDRA-9057)
 + * Add support for top-k custom 2i queries (CASSANDRA-8717)
 + * Fix error when dropping table during compaction (CASSANDRA-9251)
 + * cassandra-stress supports validation operations over user profiles (CASSANDRA-8773)
 + * Add support for rate limiting log messages (CASSANDRA-9029)
 + * Log the partition key with tombstone warnings (CASSANDRA-8561)
 + * Reduce runWithCompactionsDisabled poll interval to 1ms (CASSANDRA-9271)
 + * Fix PITR commitlog replay (CASSANDRA-9195)
 + * GCInspector logs very different times (CASSANDRA-9124)
 + * Fix deleting from an empty list (CASSANDRA-9198)
 + * Update tuple and collection types that use a user-defined type when that UDT
 +   is modified (CASSANDRA-9148, CASSANDRA-9192)
 + * Use higher timeout for prepair and snapshot in repair (CASSANDRA-9261)
 + * Fix anticompaction blocking ANTI_ENTROPY stage (CASSANDRA-9151)
 + * Repair waits for anticompaction to finish (CASSANDRA-9097)
 + * Fix streaming not holding ref when stream error (CASSANDRA-9295)
 +Merged from 2.0:
+  * Push correct protocol notification for DROP INDEX (CASSANDRA-9310)
   * token-generator - generated tokens too long (CASSANDRA-9300)
 -
 -
 -2.0.15:
   * Fix counting of tombstones for TombstoneOverwhelmingException (CASSANDRA-9299)
   * Fix ReconnectableSnitch reconnecting to peers during upgrade (CASSANDRA-6702)
   * Include keyspace and table name in error log for collections over the size

http://git-wip-us.apache.org/repos/asf/cassandra/blob/054f0a15/src/java/org/apache/cassandra/cql3/statements/DropIndexStatement.java
----------------------------------------------------------------------


[3/3] cassandra git commit: Merge branch 'cassandra-2.1' into trunk

Posted by al...@apache.org.
Merge branch 'cassandra-2.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/e1e30fc5
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/e1e30fc5
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/e1e30fc5

Branch: refs/heads/trunk
Commit: e1e30fc5e2521e48c2b02e4c20e80d319e317a1b
Parents: a16c4fe 054f0a1
Author: Aleksey Yeschenko <al...@apache.org>
Authored: Fri May 15 17:32:03 2015 +0300
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Fri May 15 17:32:03 2015 +0300

----------------------------------------------------------------------
 CHANGES.txt                                     |  1 +
 .../cql3/statements/DropIndexStatement.java     | 27 ++++++++++----------
 2 files changed, 14 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


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