cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alek...@apache.org
Subject cassandra git commit: Ninja fix table names
Date Thu, 30 Jul 2015 13:40:58 GMT
Repository: cassandra
Updated Branches:
  refs/heads/trunk f9947ff6a -> d645bfd46


Ninja fix table names


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

Branch: refs/heads/trunk
Commit: d645bfd464fcae3e8aef59a08f5eb6c7846ac11c
Parents: f9947ff
Author: Aleksey Yeschenko <aleksey@apache.org>
Authored: Thu Jul 30 16:40:23 2015 +0300
Committer: Aleksey Yeschenko <aleksey@apache.org>
Committed: Thu Jul 30 16:40:23 2015 +0300

----------------------------------------------------------------------
 .../org/apache/cassandra/db/SystemKeyspace.java | 34 ++++++++++----------
 1 file changed, 17 insertions(+), 17 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/d645bfd4/src/java/org/apache/cassandra/db/SystemKeyspace.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/db/SystemKeyspace.java b/src/java/org/apache/cassandra/db/SystemKeyspace.java
index 3d1f555..e31feaa 100644
--- a/src/java/org/apache/cassandra/db/SystemKeyspace.java
+++ b/src/java/org/apache/cassandra/db/SystemKeyspace.java
@@ -100,8 +100,8 @@ public final class SystemKeyspace
     public static final String SSTABLE_ACTIVITY = "sstable_activity";
     public static final String SIZE_ESTIMATES = "size_estimates";
     public static final String AVAILABLE_RANGES = "available_ranges";
-    public static final String MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS = "materializedviews_builds_in_progress";
-    public static final String BUILT_MATERIALIZEDVIEWS = "built_materializedviews";
+    public static final String MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS = "materialized_views_builds_in_progress";
+    public static final String BUILT_MATERIALIZED_VIEWS = "built_materialized_views";
 
     @Deprecated public static final String LEGACY_KEYSPACES = "schema_keyspaces";
     @Deprecated public static final String LEGACY_COLUMNFAMILIES = "schema_columnfamilies";
@@ -263,7 +263,7 @@ public final class SystemKeyspace
                 + "PRIMARY KEY ((keyspace_name)))");
 
     private static final CFMetaData MaterializedViewsBuildsInProgress =
-        compile(MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS,
+        compile(MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS,
                 "materialized views builds current progress",
                 "CREATE TABLE %s ("
                 + "keyspace_name text,"
@@ -273,7 +273,7 @@ public final class SystemKeyspace
                 + "PRIMARY KEY ((keyspace_name), view_name))");
 
     private static final CFMetaData BuiltMaterializedViews =
-        compile(BUILT_MATERIALIZEDVIEWS,
+        compile(BUILT_MATERIALIZED_VIEWS,
                 "built materialized views",
                 "CREATE TABLE %s ("
                 + "keyspace_name text,"
@@ -517,32 +517,32 @@ public final class SystemKeyspace
     public static boolean isViewBuilt(String keyspaceName, String viewName)
     {
         String req = "SELECT view_name FROM %s.\"%s\" WHERE keyspace_name=? AND view_name=?";
-        UntypedResultSet result = executeInternal(String.format(req, NAME, BUILT_MATERIALIZEDVIEWS),
keyspaceName, viewName);
+        UntypedResultSet result = executeInternal(String.format(req, NAME, BUILT_MATERIALIZED_VIEWS),
keyspaceName, viewName);
         return !result.isEmpty();
     }
 
     public static void setMaterializedViewBuilt(String keyspaceName, String viewName)
     {
         String req = "INSERT INTO %s.\"%s\" (keyspace_name, view_name) VALUES (?, ?)";
-        executeInternal(String.format(req, NAME, BUILT_MATERIALIZEDVIEWS), keyspaceName,
viewName);
-        forceBlockingFlush(BUILT_MATERIALIZEDVIEWS);
+        executeInternal(String.format(req, NAME, BUILT_MATERIALIZED_VIEWS), keyspaceName,
viewName);
+        forceBlockingFlush(BUILT_MATERIALIZED_VIEWS);
     }
 
 
     public static void setMaterializedViewRemoved(String keyspaceName, String viewName)
     {
         String buildReq = "DELETE FROM %S.%s WHERE keyspace_name = ? AND view_name = ?";
-        executeInternal(String.format(buildReq, NAME, MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS),
keyspaceName, viewName);
-        forceBlockingFlush(MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS);
+        executeInternal(String.format(buildReq, NAME, MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS),
keyspaceName, viewName);
+        forceBlockingFlush(MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS);
 
         String builtReq = "DELETE FROM %s.\"%s\" WHERE keyspace_name = ? AND view_name =
?";
-        executeInternal(String.format(builtReq, NAME, BUILT_MATERIALIZEDVIEWS), keyspaceName,
viewName);
-        forceBlockingFlush(BUILT_MATERIALIZEDVIEWS);
+        executeInternal(String.format(builtReq, NAME, BUILT_MATERIALIZED_VIEWS), keyspaceName,
viewName);
+        forceBlockingFlush(BUILT_MATERIALIZED_VIEWS);
     }
 
     public static void beginMaterializedViewBuild(String ksname, String viewName, int generationNumber)
     {
-        executeInternal(String.format("INSERT INTO system.%s (keyspace_name, view_name, generation_number)
VALUES (?, ?, ?)", MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS),
+        executeInternal(String.format("INSERT INTO system.%s (keyspace_name, view_name, generation_number)
VALUES (?, ?, ?)", MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS),
                         ksname,
                         viewName,
                         generationNumber);
@@ -556,22 +556,22 @@ public final class SystemKeyspace
         // Also, if the build succeeded, but the materialized view build failed, we will
be able to skip the
         // materialized view build check next boot.
         setMaterializedViewBuilt(ksname, viewName);
-        forceBlockingFlush(BUILT_MATERIALIZEDVIEWS);
-        executeInternal(String.format("DELETE FROM system.%s WHERE keyspace_name = ? AND
view_name = ?", MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS), ksname, viewName);
-        forceBlockingFlush(MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS);
+        forceBlockingFlush(BUILT_MATERIALIZED_VIEWS);
+        executeInternal(String.format("DELETE FROM system.%s WHERE keyspace_name = ? AND
view_name = ?", MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS), ksname, viewName);
+        forceBlockingFlush(MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS);
     }
 
     public static void updateMaterializedViewBuildStatus(String ksname, String viewName,
Token token)
     {
         String req = "INSERT INTO system.%s (keyspace_name, view_name, last_token) VALUES
(?, ?, ?)";
         Token.TokenFactory factory = StorageService.getPartitioner().getTokenFactory();
-        executeInternal(String.format(req, MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS), ksname,
viewName, factory.toString(token));
+        executeInternal(String.format(req, MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS), ksname,
viewName, factory.toString(token));
     }
 
     public static Pair<Integer, Token> getMaterializedViewBuildStatus(String ksname,
String viewName)
     {
         String req = "SELECT generation_number, last_token FROM system.%s WHERE keyspace_name
= ? AND view_name = ?";
-        UntypedResultSet queryResultSet = executeInternal(String.format(req, MATERIALIZEDVIEWS_BUILDS_IN_PROGRESS),
ksname, viewName);
+        UntypedResultSet queryResultSet = executeInternal(String.format(req, MATERIALIZED_VIEWS_BUILDS_IN_PROGRESS),
ksname, viewName);
         if (queryResultSet == null || queryResultSet.isEmpty())
             return null;
 


Mime
View raw message