cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From marc...@apache.org
Subject cassandra git commit: Make sure we don't add tmplink sstables to the compaction strategy
Date Thu, 22 Jan 2015 14:51:56 GMT
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.1 8092d2c65 -> 6bedeff4f


Make sure we don't add tmplink sstables to the compaction strategy

Patch by marcuse; reviewed by ayeschenko for CASSANDRA-8580


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

Branch: refs/heads/cassandra-2.1
Commit: 6bedeff4fd1af436c47e45e239f22668f84702f2
Parents: 8092d2c
Author: Marcus Eriksson <marcuse@apache.org>
Authored: Thu Jan 22 15:48:15 2015 +0100
Committer: Marcus Eriksson <marcuse@apache.org>
Committed: Thu Jan 22 15:50:18 2015 +0100

----------------------------------------------------------------------
 CHANGES.txt                                              |  2 ++
 .../db/compaction/WrappingCompactionStrategy.java        | 11 +++++++----
 2 files changed, 9 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/6bedeff4/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 54f734c..ad9cb94 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,6 @@
 2.1.3
+ * Make sure we don't add tmplink files to the compaction
+   strategy (CASSANDRA-8580)
  * (cqlsh) Handle maps with blob keys (CASSANDRA-8372)
  * (cqlsh) Handle DynamicCompositeType schemas correctly (CASSANDRA-8563)
  * Duplicate rows returned when in clause has repeated values (CASSANDRA-6707)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/6bedeff4/src/java/org/apache/cassandra/db/compaction/WrappingCompactionStrategy.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/db/compaction/WrappingCompactionStrategy.java b/src/java/org/apache/cassandra/db/compaction/WrappingCompactionStrategy.java
index c88bdf0..2f8bd7c 100644
--- a/src/java/org/apache/cassandra/db/compaction/WrappingCompactionStrategy.java
+++ b/src/java/org/apache/cassandra/db/compaction/WrappingCompactionStrategy.java
@@ -323,10 +323,13 @@ public final class WrappingCompactionStrategy extends AbstractCompactionStrategy
         super.startup();
         for (SSTableReader sstable : cfs.getSSTables())
         {
-            if (sstable.isRepaired())
-                repaired.addSSTable(sstable);
-            else
-                unrepaired.addSSTable(sstable);
+            if (sstable.openReason != SSTableReader.OpenReason.EARLY)
+            {
+                if (sstable.isRepaired())
+                    repaired.addSSTable(sstable);
+                else
+                    unrepaired.addSSTable(sstable);
+            }
         }
         repaired.startup();
         unrepaired.startup();


Mime
View raw message