cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ble...@apache.org
Subject cassandra git commit: Update StorageProxy range metrics for timeouts, failures and unavailables
Date Fri, 12 Aug 2016 13:31:30 GMT
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.2 5b38d3a81 -> e86d531ec


Update StorageProxy range metrics for timeouts, failures and unavailables

patch by Nachiket Patil; reviewed by Alex Petrov for CASSANDRA-9507


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

Branch: refs/heads/cassandra-2.2
Commit: e86d531ec2bf831a68d0bb448e5ed6ad623bbcf7
Parents: 5b38d3a
Author: Nachiket Patil <nachiket_patil@apple.com>
Authored: Fri Aug 12 15:30:03 2016 +0200
Committer: Benjamin Lerer <b.lerer@gmail.com>
Committed: Fri Aug 12 15:30:03 2016 +0200

----------------------------------------------------------------------
 CHANGES.txt                                          |  1 +
 .../org/apache/cassandra/service/StorageProxy.java   | 15 +++++++++++++++
 2 files changed, 16 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/e86d531e/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 14bed81..ddc6720 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.2.8
+ * Update StorageProxy range metrics for timeouts, failures and unavailables (CASSANDRA-9507)
  * Add Sigar to classes included in clientutil.jar (CASSANDRA-11635)
  * Add decay to histograms and timers used for metrics (CASSANDRA-11752)
  * Fix hanging stream session (CASSANDRA-10992)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/e86d531e/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 03dd209..7b7979d 100644
--- a/src/java/org/apache/cassandra/service/StorageProxy.java
+++ b/src/java/org/apache/cassandra/service/StorageProxy.java
@@ -1955,6 +1955,21 @@ public class StorageProxy implements StorageProxyMBean
                 }
             }
         }
+        catch (ReadTimeoutException e)
+        {
+            rangeMetrics.timeouts.mark();
+            throw e;
+        }
+        catch (UnavailableException e)
+        {
+            rangeMetrics.unavailables.mark();
+            throw e;
+        }
+        catch (ReadFailureException e)
+        {
+            rangeMetrics.failures.mark();
+            throw e;
+        }
         finally
         {
             long latency = System.nanoTime() - startTime;


Mime
View raw message