You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by al...@apache.org on 2015/03/27 08:11:07 UTC
cassandra git commit: Prevent AssertionError from
SizeEstimatesRecorder
Repository: cassandra
Updated Branches:
refs/heads/cassandra-2.1 b66092f90 -> bd4842410
Prevent AssertionError from SizeEstimatesRecorder
patch by Carl Yeksigian; reviewed by Stefania Alborghetti for
CASSANDRA-9034
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/bd484241
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/bd484241
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/bd484241
Branch: refs/heads/cassandra-2.1
Commit: bd4842410e73574dff8f3a51bd95e414f76ed506
Parents: b66092f
Author: Carl Yeksigian <ca...@apache.org>
Authored: Thu Mar 26 14:58:46 2015 -0400
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Fri Mar 27 10:08:54 2015 +0300
----------------------------------------------------------------------
CHANGES.txt | 1 +
src/java/org/apache/cassandra/db/SizeEstimatesRecorder.java | 6 ++++++
2 files changed, 7 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/bd484241/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index dba397c..3f5571e 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
2.1.4
+ * Prevent AssertionError from SizeEstimatesRecorder (CASSANDRA-9034)
* Avoid overwriting index summaries for sstables with an older format that
does not support downsampling; rebuild summaries on startup when this
is detected (CASSANDRA-8993)
http://git-wip-us.apache.org/repos/asf/cassandra/blob/bd484241/src/java/org/apache/cassandra/db/SizeEstimatesRecorder.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/db/SizeEstimatesRecorder.java b/src/java/org/apache/cassandra/db/SizeEstimatesRecorder.java
index 1472c11..13d9c60 100644
--- a/src/java/org/apache/cassandra/db/SizeEstimatesRecorder.java
+++ b/src/java/org/apache/cassandra/db/SizeEstimatesRecorder.java
@@ -55,6 +55,12 @@ public class SizeEstimatesRecorder extends MigrationListener implements Runnable
public void run()
{
+ if (StorageService.instance.isStarting())
+ {
+ logger.debug("Node has not yet joined; not recording size estimates");
+ return;
+ }
+
logger.debug("Recording size estimates");
// find primary token ranges for the local node.