cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From marc...@apache.org
Subject [1/2] cassandra git commit: Check if the filtered sstables are empty in STCS
Date Tue, 24 Feb 2015 12:27:48 GMT
Repository: cassandra
Updated Branches:
  refs/heads/trunk ee5e48795 -> b944f0d66


Check if the filtered sstables are empty in STCS

Patch by jjordan; reviewed by marcuse for CASSANDRA-8843


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

Branch: refs/heads/trunk
Commit: 0a7f50876352d4579bd5e6309285d14bc1842990
Parents: 407b5de
Author: Marcus Eriksson <marcuse@apache.org>
Authored: Tue Feb 24 13:21:46 2015 +0100
Committer: Marcus Eriksson <marcuse@apache.org>
Committed: Tue Feb 24 13:25:34 2015 +0100

----------------------------------------------------------------------
 CHANGES.txt                                                        | 1 +
 .../cassandra/db/compaction/SizeTieredCompactionStrategy.java      | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/0a7f5087/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index d9560fc..b1bc26f 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.1.4
+ * Check if the filtered sstables is non-empty in STCS (CASSANDRA-8843)
  * Upgrade java-driver used for cassandra-stress (CASSANDRA-8842)
  * Fix CommitLog.forceRecycleAllSegments() memory access error (CASSANDRA-8812)
  * Improve assertions in Memory (CASSANDRA-8792)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/0a7f5087/src/java/org/apache/cassandra/db/compaction/SizeTieredCompactionStrategy.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/db/compaction/SizeTieredCompactionStrategy.java
b/src/java/org/apache/cassandra/db/compaction/SizeTieredCompactionStrategy.java
index 8b1610e..08102c1 100644
--- a/src/java/org/apache/cassandra/db/compaction/SizeTieredCompactionStrategy.java
+++ b/src/java/org/apache/cassandra/db/compaction/SizeTieredCompactionStrategy.java
@@ -330,7 +330,7 @@ public class SizeTieredCompactionStrategy extends AbstractCompactionStrategy
     public Collection<AbstractCompactionTask> getMaximalTask(final int gcBefore)
     {
         Iterable<SSTableReader> filteredSSTables = filterSuspectSSTables(sstables);
-        if (Iterables.isEmpty(sstables))
+        if (Iterables.isEmpty(filteredSSTables))
             return null;
         if (!cfs.getDataTracker().markCompacting(filteredSSTables))
             return null;


Mime
View raw message