You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by jb...@apache.org on 2013/12/05 16:44:25 UTC
[1/6] git commit: Fix cache persistence when both row and key cache
are enabled patch by Mikhail Stepura and jbellis for CASSANDRA-6413
Updated Branches:
refs/heads/cassandra-1.2 e40bc759c -> 57613dc8c
refs/heads/cassandra-2.0 cf83c81d8 -> 667e3db91
refs/heads/trunk 6772247f8 -> 5ad8a3d3a
Fix cache persistence when both row and key cache are enabled
patch by Mikhail Stepura and jbellis for CASSANDRA-6413
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/57613dc8
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/57613dc8
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/57613dc8
Branch: refs/heads/cassandra-1.2
Commit: 57613dc8c14d7213ee2d46d41bd642dd7cf697ab
Parents: e40bc75
Author: Jonathan Ellis <jb...@apache.org>
Authored: Thu Dec 5 09:42:41 2013 -0600
Committer: Jonathan Ellis <jb...@apache.org>
Committed: Thu Dec 5 09:42:41 2013 -0600
----------------------------------------------------------------------
CHANGES.txt | 5 ++++-
.../apache/cassandra/cache/AutoSavingCache.java | 22 ++++++++------------
2 files changed, 13 insertions(+), 14 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/57613dc8/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 09a3b07..166c566 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -2,7 +2,8 @@
* Fix thundering herd on endpoint cache invalidation (CASSANDRA-6345)
* Optimize FD phi calculation (CASSANDRA-6386)
* Improve initial FD phi estimate when starting up (CASSANDRA-6385)
- * Don't list CQL3 table in CLI describe even if named explicitely (CASSANDRA-5750)
+ * Don't list CQL3 table in CLI describe even if named explicitely
+ (CASSANDRA-5750)
* cqlsh: quote single quotes in strings inside collections (CASSANDRA-6172)
* Improve gossip performance for typical messages (CASSANDRA-6409)
* Throw IRE if a prepared statement has more markers than supported
@@ -11,6 +12,8 @@
* Change snapshot response message verb to INTERNAL to avoid dropping it
(CASSANDRA-6415)
* Warn when collection read has > 65K elements (CASSANDRA-5428)
+ * Fix cache persistence when both row and key cache are enabled
+ (CASSANDRA-6413)
1.2.12
http://git-wip-us.apache.org/repos/asf/cassandra/blob/57613dc8/src/java/org/apache/cassandra/cache/AutoSavingCache.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/cache/AutoSavingCache.java b/src/java/org/apache/cassandra/cache/AutoSavingCache.java
index d6a37df..a649e88 100644
--- a/src/java/org/apache/cassandra/cache/AutoSavingCache.java
+++ b/src/java/org/apache/cassandra/cache/AutoSavingCache.java
@@ -299,22 +299,18 @@ public class AutoSavingCache<K extends CacheKey, V> extends InstrumentingCache<K
private void deleteOldCacheFiles()
{
File savedCachesDir = new File(DatabaseDescriptor.getSavedCachesLocation());
+ assert savedCachesDir.exists() && savedCachesDir.isDirectory();
- if (savedCachesDir.exists() && savedCachesDir.isDirectory())
+ for (File file : savedCachesDir.listFiles())
{
- for (File file : savedCachesDir.listFiles())
- {
- if (file.isFile() && file.getName().endsWith(cacheType.toString()))
- {
- if (!file.delete())
- logger.warn("Failed to delete {}", file.getAbsolutePath());
- }
+ if (!file.isFile())
+ continue; // someone's been messing with our directory. naughty!
- if (file.isFile() && file.getName().endsWith(CURRENT_VERSION + ".db"))
- {
- if (!file.delete())
- logger.warn("Failed to delete {}", file.getAbsolutePath());
- }
+ if (file.getName().endsWith(cacheType.toString())
+ || file.getName().endsWith(String.format("%s-%s.db", cacheType.toString(), CURRENT_VERSION)))
+ {
+ if (!file.delete())
+ logger.warn("Failed to delete {}", file.getAbsolutePath());
}
}
}
[6/6] git commit: Merge branch 'cassandra-2.0' into trunk
Posted by jb...@apache.org.
Merge branch 'cassandra-2.0' into trunk
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/5ad8a3d3
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/5ad8a3d3
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/5ad8a3d3
Branch: refs/heads/trunk
Commit: 5ad8a3d3aa94b864f72ca587d9117f1458a47f34
Parents: 6772247 667e3db
Author: Jonathan Ellis <jb...@apache.org>
Authored: Thu Dec 5 09:44:18 2013 -0600
Committer: Jonathan Ellis <jb...@apache.org>
Committed: Thu Dec 5 09:44:18 2013 -0600
----------------------------------------------------------------------
CHANGES.txt | 5 ++++-
.../apache/cassandra/cache/AutoSavingCache.java | 22 ++++++++------------
2 files changed, 13 insertions(+), 14 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/5ad8a3d3/CHANGES.txt
----------------------------------------------------------------------
[3/6] git commit: Fix cache persistence when both row and key cache
are enabled patch by Mikhail Stepura and jbellis for CASSANDRA-6413
Posted by jb...@apache.org.
Fix cache persistence when both row and key cache are enabled
patch by Mikhail Stepura and jbellis for CASSANDRA-6413
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/57613dc8
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/57613dc8
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/57613dc8
Branch: refs/heads/trunk
Commit: 57613dc8c14d7213ee2d46d41bd642dd7cf697ab
Parents: e40bc75
Author: Jonathan Ellis <jb...@apache.org>
Authored: Thu Dec 5 09:42:41 2013 -0600
Committer: Jonathan Ellis <jb...@apache.org>
Committed: Thu Dec 5 09:42:41 2013 -0600
----------------------------------------------------------------------
CHANGES.txt | 5 ++++-
.../apache/cassandra/cache/AutoSavingCache.java | 22 ++++++++------------
2 files changed, 13 insertions(+), 14 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/57613dc8/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 09a3b07..166c566 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -2,7 +2,8 @@
* Fix thundering herd on endpoint cache invalidation (CASSANDRA-6345)
* Optimize FD phi calculation (CASSANDRA-6386)
* Improve initial FD phi estimate when starting up (CASSANDRA-6385)
- * Don't list CQL3 table in CLI describe even if named explicitely (CASSANDRA-5750)
+ * Don't list CQL3 table in CLI describe even if named explicitely
+ (CASSANDRA-5750)
* cqlsh: quote single quotes in strings inside collections (CASSANDRA-6172)
* Improve gossip performance for typical messages (CASSANDRA-6409)
* Throw IRE if a prepared statement has more markers than supported
@@ -11,6 +12,8 @@
* Change snapshot response message verb to INTERNAL to avoid dropping it
(CASSANDRA-6415)
* Warn when collection read has > 65K elements (CASSANDRA-5428)
+ * Fix cache persistence when both row and key cache are enabled
+ (CASSANDRA-6413)
1.2.12
http://git-wip-us.apache.org/repos/asf/cassandra/blob/57613dc8/src/java/org/apache/cassandra/cache/AutoSavingCache.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/cache/AutoSavingCache.java b/src/java/org/apache/cassandra/cache/AutoSavingCache.java
index d6a37df..a649e88 100644
--- a/src/java/org/apache/cassandra/cache/AutoSavingCache.java
+++ b/src/java/org/apache/cassandra/cache/AutoSavingCache.java
@@ -299,22 +299,18 @@ public class AutoSavingCache<K extends CacheKey, V> extends InstrumentingCache<K
private void deleteOldCacheFiles()
{
File savedCachesDir = new File(DatabaseDescriptor.getSavedCachesLocation());
+ assert savedCachesDir.exists() && savedCachesDir.isDirectory();
- if (savedCachesDir.exists() && savedCachesDir.isDirectory())
+ for (File file : savedCachesDir.listFiles())
{
- for (File file : savedCachesDir.listFiles())
- {
- if (file.isFile() && file.getName().endsWith(cacheType.toString()))
- {
- if (!file.delete())
- logger.warn("Failed to delete {}", file.getAbsolutePath());
- }
+ if (!file.isFile())
+ continue; // someone's been messing with our directory. naughty!
- if (file.isFile() && file.getName().endsWith(CURRENT_VERSION + ".db"))
- {
- if (!file.delete())
- logger.warn("Failed to delete {}", file.getAbsolutePath());
- }
+ if (file.getName().endsWith(cacheType.toString())
+ || file.getName().endsWith(String.format("%s-%s.db", cacheType.toString(), CURRENT_VERSION)))
+ {
+ if (!file.delete())
+ logger.warn("Failed to delete {}", file.getAbsolutePath());
}
}
}
[5/6] git commit: merge from 1.2
Posted by jb...@apache.org.
merge from 1.2
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/667e3db9
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/667e3db9
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/667e3db9
Branch: refs/heads/cassandra-2.0
Commit: 667e3db91cbec9928857aa89bfcc63fe85cb558d
Parents: cf83c81 57613dc
Author: Jonathan Ellis <jb...@apache.org>
Authored: Thu Dec 5 09:44:10 2013 -0600
Committer: Jonathan Ellis <jb...@apache.org>
Committed: Thu Dec 5 09:44:10 2013 -0600
----------------------------------------------------------------------
CHANGES.txt | 5 ++++-
.../apache/cassandra/cache/AutoSavingCache.java | 22 ++++++++------------
2 files changed, 13 insertions(+), 14 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/667e3db9/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index d485a69,166c566..8996965
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -16,44 -12,11 +16,47 @@@ Merged from 1.2
* Change snapshot response message verb to INTERNAL to avoid dropping it
(CASSANDRA-6415)
* Warn when collection read has > 65K elements (CASSANDRA-5428)
+ * Fix cache persistence when both row and key cache are enabled
+ (CASSANDRA-6413)
-1.2.12
+2.0.3
+ * Fix FD leak on slice read path (CASSANDRA-6275)
+ * Cancel read meter task when closing SSTR (CASSANDRA-6358)
+ * free off-heap IndexSummary during bulk (CASSANDRA-6359)
+ * Recover from IOException in accept() thread (CASSANDRA-6349)
+ * Improve Gossip tolerance of abnormally slow tasks (CASSANDRA-6338)
+ * Fix trying to hint timed out counter writes (CASSANDRA-6322)
+ * Allow restoring specific columnfamilies from archived CL (CASSANDRA-4809)
+ * Avoid flushing compaction_history after each operation (CASSANDRA-6287)
+ * Fix repair assertion error when tombstones expire (CASSANDRA-6277)
+ * Skip loading corrupt key cache (CASSANDRA-6260)
+ * Fixes for compacting larger-than-memory rows (CASSANDRA-6274)
+ * Compact hottest sstables first and optionally omit coldest from
+ compaction entirely (CASSANDRA-6109)
+ * Fix modifying column_metadata from thrift (CASSANDRA-6182)
+ * cqlsh: fix LIST USERS output (CASSANDRA-6242)
+ * Add IRequestSink interface (CASSANDRA-6248)
+ * Update memtable size while flushing (CASSANDRA-6249)
+ * Provide hooks around CQL2/CQL3 statement execution (CASSANDRA-6252)
+ * Require Permission.SELECT for CAS updates (CASSANDRA-6247)
+ * New CQL-aware SSTableWriter (CASSANDRA-5894)
+ * Reject CAS operation when the protocol v1 is used (CASSANDRA-6270)
+ * Correctly throw error when frame too large (CASSANDRA-5981)
+ * Fix serialization bug in PagedRange with 2ndary indexes (CASSANDRA-6299)
+ * Fix CQL3 table validation in Thrift (CASSANDRA-6140)
+ * Fix bug missing results with IN clauses (CASSANDRA-6327)
+ * Fix paging with reversed slices (CASSANDRA-6343)
+ * Set minTimestamp correctly to be able to drop expired sstables (CASSANDRA-6337)
+ * Support NaN and Infinity as float literals (CASSANDRA-6003)
+ * Remove RF from nodetool ring output (CASSANDRA-6289)
+ * Fix attempting to flush empty rows (CASSANDRA-6374)
+ * Fix potential out of bounds exception when paging (CASSANDRA-6333)
+Merged from 1.2:
+ * Optimize FD phi calculation (CASSANDRA-6386)
+ * Improve initial FD phi estimate when starting up (CASSANDRA-6385)
- * Don't list CQL3 table in CLI describe even if named explicitely (CASSANDRA-5750)
++ * Don't list CQL3 table in CLI describe even if named explicitely
++ (CASSANDRA-5750)
* Invalidate row cache when dropping CF (CASSANDRA-6351)
* add non-jamm path for cached statements (CASSANDRA-6293)
* (Hadoop) Require CFRR batchSize to be at least 2 (CASSANDRA-6114)
http://git-wip-us.apache.org/repos/asf/cassandra/blob/667e3db9/src/java/org/apache/cassandra/cache/AutoSavingCache.java
----------------------------------------------------------------------
[4/6] git commit: merge from 1.2
Posted by jb...@apache.org.
merge from 1.2
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/667e3db9
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/667e3db9
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/667e3db9
Branch: refs/heads/trunk
Commit: 667e3db91cbec9928857aa89bfcc63fe85cb558d
Parents: cf83c81 57613dc
Author: Jonathan Ellis <jb...@apache.org>
Authored: Thu Dec 5 09:44:10 2013 -0600
Committer: Jonathan Ellis <jb...@apache.org>
Committed: Thu Dec 5 09:44:10 2013 -0600
----------------------------------------------------------------------
CHANGES.txt | 5 ++++-
.../apache/cassandra/cache/AutoSavingCache.java | 22 ++++++++------------
2 files changed, 13 insertions(+), 14 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/667e3db9/CHANGES.txt
----------------------------------------------------------------------
diff --cc CHANGES.txt
index d485a69,166c566..8996965
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@@ -16,44 -12,11 +16,47 @@@ Merged from 1.2
* Change snapshot response message verb to INTERNAL to avoid dropping it
(CASSANDRA-6415)
* Warn when collection read has > 65K elements (CASSANDRA-5428)
+ * Fix cache persistence when both row and key cache are enabled
+ (CASSANDRA-6413)
-1.2.12
+2.0.3
+ * Fix FD leak on slice read path (CASSANDRA-6275)
+ * Cancel read meter task when closing SSTR (CASSANDRA-6358)
+ * free off-heap IndexSummary during bulk (CASSANDRA-6359)
+ * Recover from IOException in accept() thread (CASSANDRA-6349)
+ * Improve Gossip tolerance of abnormally slow tasks (CASSANDRA-6338)
+ * Fix trying to hint timed out counter writes (CASSANDRA-6322)
+ * Allow restoring specific columnfamilies from archived CL (CASSANDRA-4809)
+ * Avoid flushing compaction_history after each operation (CASSANDRA-6287)
+ * Fix repair assertion error when tombstones expire (CASSANDRA-6277)
+ * Skip loading corrupt key cache (CASSANDRA-6260)
+ * Fixes for compacting larger-than-memory rows (CASSANDRA-6274)
+ * Compact hottest sstables first and optionally omit coldest from
+ compaction entirely (CASSANDRA-6109)
+ * Fix modifying column_metadata from thrift (CASSANDRA-6182)
+ * cqlsh: fix LIST USERS output (CASSANDRA-6242)
+ * Add IRequestSink interface (CASSANDRA-6248)
+ * Update memtable size while flushing (CASSANDRA-6249)
+ * Provide hooks around CQL2/CQL3 statement execution (CASSANDRA-6252)
+ * Require Permission.SELECT for CAS updates (CASSANDRA-6247)
+ * New CQL-aware SSTableWriter (CASSANDRA-5894)
+ * Reject CAS operation when the protocol v1 is used (CASSANDRA-6270)
+ * Correctly throw error when frame too large (CASSANDRA-5981)
+ * Fix serialization bug in PagedRange with 2ndary indexes (CASSANDRA-6299)
+ * Fix CQL3 table validation in Thrift (CASSANDRA-6140)
+ * Fix bug missing results with IN clauses (CASSANDRA-6327)
+ * Fix paging with reversed slices (CASSANDRA-6343)
+ * Set minTimestamp correctly to be able to drop expired sstables (CASSANDRA-6337)
+ * Support NaN and Infinity as float literals (CASSANDRA-6003)
+ * Remove RF from nodetool ring output (CASSANDRA-6289)
+ * Fix attempting to flush empty rows (CASSANDRA-6374)
+ * Fix potential out of bounds exception when paging (CASSANDRA-6333)
+Merged from 1.2:
+ * Optimize FD phi calculation (CASSANDRA-6386)
+ * Improve initial FD phi estimate when starting up (CASSANDRA-6385)
- * Don't list CQL3 table in CLI describe even if named explicitely (CASSANDRA-5750)
++ * Don't list CQL3 table in CLI describe even if named explicitely
++ (CASSANDRA-5750)
* Invalidate row cache when dropping CF (CASSANDRA-6351)
* add non-jamm path for cached statements (CASSANDRA-6293)
* (Hadoop) Require CFRR batchSize to be at least 2 (CASSANDRA-6114)
http://git-wip-us.apache.org/repos/asf/cassandra/blob/667e3db9/src/java/org/apache/cassandra/cache/AutoSavingCache.java
----------------------------------------------------------------------
[2/6] git commit: Fix cache persistence when both row and key cache
are enabled patch by Mikhail Stepura and jbellis for CASSANDRA-6413
Posted by jb...@apache.org.
Fix cache persistence when both row and key cache are enabled
patch by Mikhail Stepura and jbellis for CASSANDRA-6413
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/57613dc8
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/57613dc8
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/57613dc8
Branch: refs/heads/cassandra-2.0
Commit: 57613dc8c14d7213ee2d46d41bd642dd7cf697ab
Parents: e40bc75
Author: Jonathan Ellis <jb...@apache.org>
Authored: Thu Dec 5 09:42:41 2013 -0600
Committer: Jonathan Ellis <jb...@apache.org>
Committed: Thu Dec 5 09:42:41 2013 -0600
----------------------------------------------------------------------
CHANGES.txt | 5 ++++-
.../apache/cassandra/cache/AutoSavingCache.java | 22 ++++++++------------
2 files changed, 13 insertions(+), 14 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/57613dc8/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 09a3b07..166c566 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -2,7 +2,8 @@
* Fix thundering herd on endpoint cache invalidation (CASSANDRA-6345)
* Optimize FD phi calculation (CASSANDRA-6386)
* Improve initial FD phi estimate when starting up (CASSANDRA-6385)
- * Don't list CQL3 table in CLI describe even if named explicitely (CASSANDRA-5750)
+ * Don't list CQL3 table in CLI describe even if named explicitely
+ (CASSANDRA-5750)
* cqlsh: quote single quotes in strings inside collections (CASSANDRA-6172)
* Improve gossip performance for typical messages (CASSANDRA-6409)
* Throw IRE if a prepared statement has more markers than supported
@@ -11,6 +12,8 @@
* Change snapshot response message verb to INTERNAL to avoid dropping it
(CASSANDRA-6415)
* Warn when collection read has > 65K elements (CASSANDRA-5428)
+ * Fix cache persistence when both row and key cache are enabled
+ (CASSANDRA-6413)
1.2.12
http://git-wip-us.apache.org/repos/asf/cassandra/blob/57613dc8/src/java/org/apache/cassandra/cache/AutoSavingCache.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/cache/AutoSavingCache.java b/src/java/org/apache/cassandra/cache/AutoSavingCache.java
index d6a37df..a649e88 100644
--- a/src/java/org/apache/cassandra/cache/AutoSavingCache.java
+++ b/src/java/org/apache/cassandra/cache/AutoSavingCache.java
@@ -299,22 +299,18 @@ public class AutoSavingCache<K extends CacheKey, V> extends InstrumentingCache<K
private void deleteOldCacheFiles()
{
File savedCachesDir = new File(DatabaseDescriptor.getSavedCachesLocation());
+ assert savedCachesDir.exists() && savedCachesDir.isDirectory();
- if (savedCachesDir.exists() && savedCachesDir.isDirectory())
+ for (File file : savedCachesDir.listFiles())
{
- for (File file : savedCachesDir.listFiles())
- {
- if (file.isFile() && file.getName().endsWith(cacheType.toString()))
- {
- if (!file.delete())
- logger.warn("Failed to delete {}", file.getAbsolutePath());
- }
+ if (!file.isFile())
+ continue; // someone's been messing with our directory. naughty!
- if (file.isFile() && file.getName().endsWith(CURRENT_VERSION + ".db"))
- {
- if (!file.delete())
- logger.warn("Failed to delete {}", file.getAbsolutePath());
- }
+ if (file.getName().endsWith(cacheType.toString())
+ || file.getName().endsWith(String.format("%s-%s.db", cacheType.toString(), CURRENT_VERSION)))
+ {
+ if (!file.delete())
+ logger.warn("Failed to delete {}", file.getAbsolutePath());
}
}
}