Updated Branches: refs/heads/cassandra-2.0 83feb94e7 -> fb9b3d57d
Don't announce schema version until we've loaded the changes locally patch by slebresne; reviewed by iamaleksey for CASSANDRA-5904 Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/1df9823a Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/1df9823a Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/1df9823a Branch: refs/heads/cassandra-2.0 Commit: 1df9823a68e0a91e2a5f2cef21217e6b65f8204a Parents: bc98886 Author: Sylvain Lebresne <sylv...@datastax.com> Authored: Tue Aug 20 16:30:24 2013 +0200 Committer: Sylvain Lebresne <sylv...@datastax.com> Committed: Tue Aug 20 16:30:24 2013 +0200 ---------------------------------------------------------------------- CHANGES.txt | 2 ++ src/java/org/apache/cassandra/db/DefsTable.java | 3 +-- 2 files changed, 3 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cassandra/blob/1df9823a/CHANGES.txt ---------------------------------------------------------------------- diff --git a/CHANGES.txt b/CHANGES.txt index bc3f2c6..7ecf602 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -20,6 +20,8 @@ * cqlsh: add support for multiline comments (CASSANDRA-5798) * Handle CQL3 SELECT duplicate IN restrictions on clustering columns (CASSANDRA-5856) + * Don't announce schema version until we've loaded the changes locally + (CASSANDRA-5904) Merged from 1.1: * Correctly validate sparse composite cells in scrub (CASSANDRA-5855) http://git-wip-us.apache.org/repos/asf/cassandra/blob/1df9823a/src/java/org/apache/cassandra/db/DefsTable.java ---------------------------------------------------------------------- diff --git a/src/java/org/apache/cassandra/db/DefsTable.java b/src/java/org/apache/cassandra/db/DefsTable.java index 4e9cf01..146ea28 100644 --- a/src/java/org/apache/cassandra/db/DefsTable.java +++ b/src/java/org/apache/cassandra/db/DefsTable.java @@ -348,8 +348,6 @@ public class DefsTable if (!StorageService.instance.isClientMode()) flushSchemaCFs(); - Schema.instance.updateVersionAndAnnounce(); - // with new data applied Map<DecoratedKey, ColumnFamily> newKeyspaces = SystemTable.getSchema(SystemTable.SCHEMA_KEYSPACES_CF); Map<DecoratedKey, ColumnFamily> newColumnFamilies = SystemTable.getSchema(SystemTable.SCHEMA_COLUMNFAMILIES_CF); @@ -361,6 +359,7 @@ public class DefsTable for (String keyspaceToDrop : keyspacesToDrop) dropKeyspace(keyspaceToDrop); + Schema.instance.updateVersionAndAnnounce(); } private static Set<String> mergeKeyspaces(Map<DecoratedKey, ColumnFamily> old, Map<DecoratedKey, ColumnFamily> updated)