You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by sa...@apache.org on 2016/01/05 11:53:40 UTC

[06/10] cassandra git commit: Merge branch 'cassandra-2.2' into cassandra-3.0

Merge branch 'cassandra-2.2' into cassandra-3.0


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

Branch: refs/heads/cassandra-3.0
Commit: 5ad81149444fa9cc3d5b51d9140c641081423f28
Parents: 025384c 9dafa43
Author: Sam Tunnicliffe <sa...@beobal.com>
Authored: Tue Jan 5 10:21:22 2016 +0000
Committer: Sam Tunnicliffe <sa...@beobal.com>
Committed: Tue Jan 5 10:26:39 2016 +0000

----------------------------------------------------------------------
 CHANGES.txt                                              | 1 +
 src/java/org/apache/cassandra/service/StartupChecks.java | 9 ++++++++-
 2 files changed, 9 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/5ad81149/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index bcc4c91,3c919c7..beb59b0
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -1,17 -1,8 +1,18 @@@
 -2.2.5
 +3.0.3
 + * Fix counting of received sstables in streaming (CASSANDRA-10949)
 + * Implement hints compression (CASSANDRA-9428)
 + * Fix potential assertion error when reading static columns (CASSANDRA-10903)
 + * Avoid NoSuchElementException when executing empty batch (CASSANDRA-10711)
 + * Avoid building PartitionUpdate in toString (CASSANDRA-10897)
 + * Reduce heap spent when receiving many SSTables (CASSANDRA-10797)
 + * Add back support for 3rd party auth providers to bulk loader (CASSANDRA-10873)
 + * Eliminate the dependency on jgrapht for UDT resolution (CASSANDRA-10653)
 + * (Hadoop) Close Clusters and Sessions in Hadoop Input/Output classes (CASSANDRA-10837)
 + * Fix sstableloader not working with upper case keyspace name (CASSANDRA-10806)
 +Merged from 2.2:
+  * Skip commit log and saved cache directories in SSTable version startup check (CASSANDRA-10902)
   * drop/alter user should be case sensitive (CASSANDRA-10817)
   * jemalloc detection fails due to quoting issues in regexv (CASSANDRA-10946)
 - * Support counter-columns for native aggregates (sum,avg,max,min) (CASSANDRA-9977)
   * (cqlsh) show correct column names for empty result sets (CASSANDRA-9813)
   * Add new types to Stress (CASSANDRA-9556)
   * Add property to allow listening on broadcast interface (CASSANDRA-9748)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/5ad81149/src/java/org/apache/cassandra/service/StartupChecks.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/service/StartupChecks.java
index c2c5acc,19f32b6..b405bed
--- a/src/java/org/apache/cassandra/service/StartupChecks.java
+++ b/src/java/org/apache/cassandra/service/StartupChecks.java
@@@ -230,6 -234,10 +231,11 @@@ public class StartupCheck
          public void execute() throws StartupException
          {
              final Set<String> invalid = new HashSet<>();
+             final Set<String> nonSSTablePaths = new HashSet<>();
+             nonSSTablePaths.add(FileUtils.getCanonicalPath(DatabaseDescriptor.getCommitLogLocation()));
+             nonSSTablePaths.add(FileUtils.getCanonicalPath(DatabaseDescriptor.getSavedCachesLocation()));
++            nonSSTablePaths.add(FileUtils.getCanonicalPath(DatabaseDescriptor.getHintsDirectory()));
+ 
              FileVisitor<Path> sstableVisitor = new SimpleFileVisitor<Path>()
              {
                  public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) throws IOException
@@@ -252,8 -260,9 +258,9 @@@
                  public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs) throws IOException
                  {
                      String name = dir.getFileName().toString();
 -                    return (name.equals("snapshots")
 -                            || name.equals("backups")
 +                    return (name.equals(Directories.SNAPSHOT_SUBDIR)
-                             || name.equals(Directories.BACKUPS_SUBDIR))
++                            || name.equals(Directories.BACKUPS_SUBDIR)
+                             || nonSSTablePaths.contains(dir.toFile().getCanonicalPath()))
                             ? FileVisitResult.SKIP_SUBTREE
                             : FileVisitResult.CONTINUE;
                  }