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 2014/12/11 15:18:33 UTC
cassandra git commit: Fix error message on read repair timeouts
Repository: cassandra
Updated Branches:
refs/heads/cassandra-2.0 578430952 -> 451c514a3
Fix error message on read repair timeouts
patch by Sam Tunnicliffe; reviewed by Aleksey Yeschenko for
CASSANDRA-7947
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/451c514a
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/451c514a
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/451c514a
Branch: refs/heads/cassandra-2.0
Commit: 451c514a3a02f4e889f040176453beefbcd75843
Parents: 5784309
Author: Sam Tunnicliffe <sa...@beobal.com>
Authored: Thu Dec 11 15:17:29 2014 +0100
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Thu Dec 11 15:17:29 2014 +0100
----------------------------------------------------------------------
CHANGES.txt | 1 +
.../org/apache/cassandra/service/StorageProxy.java | 16 +++++++++++++++-
2 files changed, 16 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/451c514a/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 385af01..cd302fb 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
2.0.12:
+ * Fix error message on read repair timeouts (CASSANDRA-7947)
* Default DTCS base_time_seconds changed to 60 (CASSANDRA-8417)
* Refuse Paxos operation with more than one pending endpoint (CASSANDRA-8346)
* Throw correct exception when trying to bind a keyspace or table
http://git-wip-us.apache.org/repos/asf/cassandra/blob/451c514a/src/java/org/apache/cassandra/service/StorageProxy.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/service/StorageProxy.java b/src/java/org/apache/cassandra/service/StorageProxy.java
index f877aee..1e1a2a3 100644
--- a/src/java/org/apache/cassandra/service/StorageProxy.java
+++ b/src/java/org/apache/cassandra/service/StorageProxy.java
@@ -1368,6 +1368,17 @@ public class StorageProxy implements StorageProxyMBean
{
throw new AssertionError(e); // full data requested from each node here, no digests should be sent
}
+ catch (ReadTimeoutException e)
+ {
+ if (Tracing.isTracing())
+ Tracing.trace("Timed out waiting on digest mismatch repair requests");
+ else
+ logger.debug("Timed out waiting on digest mismatch repair requests");
+ // the caught exception here will have CL.ALL from the repair command,
+ // not whatever CL the initial command was at (CASSANDRA-7947)
+ int blockFor = consistencyLevel.blockFor(Keyspace.open(command.getKeyspace()));
+ throw new ReadTimeoutException(consistencyLevel, blockFor-1, blockFor, true);
+ }
RowDataResolver resolver = (RowDataResolver)handler.resolver;
try
@@ -1378,7 +1389,10 @@ public class StorageProxy implements StorageProxyMBean
}
catch (TimeoutException e)
{
- Tracing.trace("Timed out on digest mismatch retries");
+ if (Tracing.isTracing())
+ Tracing.trace("Timed out waiting on digest mismatch repair acknowledgements");
+ else
+ logger.debug("Timed out waiting on digest mismatch repair acknowledgements");
int blockFor = consistencyLevel.blockFor(Keyspace.open(command.getKeyspace()));
throw new ReadTimeoutException(consistencyLevel, blockFor-1, blockFor, true);
}