cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yu...@apache.org
Subject [02/15] cassandra git commit: Add message dropped tasks to nodetool netstats
Date Mon, 23 May 2016 15:01:25 GMT
Add message dropped tasks to nodetool netstats

patch by Jeremiah Jordan; reviewed by yukim for CASSANDRA-11855


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

Branch: refs/heads/cassandra-2.2
Commit: 129b1193e26c015fd06ed652eb62dcd509b6bc50
Parents: 00f2540
Author: Jeremiah D Jordan <jeremiah@datastax.com>
Authored: Fri May 20 11:44:44 2016 -0500
Committer: Yuki Morishita <yukim@apache.org>
Committed: Mon May 23 09:27:13 2016 -0500

----------------------------------------------------------------------
 CHANGES.txt                                       |  1 +
 src/java/org/apache/cassandra/tools/NodeTool.java | 11 ++++++++---
 2 files changed, 9 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/129b1193/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 3972248..7a0ccba 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.1.15
+ * Add message dropped tasks to nodetool netstats (CASSANDRA-11855)
  * Don't compute expensive MaxPurgeableTimestamp until we've verified there's an 
    expired tombstone (CASSANDRA-11834)
  * Fix paging on DISTINCT queries repeats result when first row in partition changes 

http://git-wip-us.apache.org/repos/asf/cassandra/blob/129b1193/src/java/org/apache/cassandra/tools/NodeTool.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/tools/NodeTool.java b/src/java/org/apache/cassandra/tools/NodeTool.java
index 1de2e20..5af8240 100644
--- a/src/java/org/apache/cassandra/tools/NodeTool.java
+++ b/src/java/org/apache/cassandra/tools/NodeTool.java
@@ -708,10 +708,12 @@ public class NodeTool
                 System.out.printf("%-25s", "Pool Name");
                 System.out.printf("%10s", "Active");
                 System.out.printf("%10s", "Pending");
-                System.out.printf("%15s%n", "Completed");
+                System.out.printf("%15s", "Completed");
+                System.out.printf("%10s%n", "Dropped");
 
                 int pending;
                 long completed;
+                long dropped;
 
                 pending = 0;
                 for (int n : ms.getCommandPendingTasks().values())
@@ -719,7 +721,10 @@ public class NodeTool
                 completed = 0;
                 for (long n : ms.getCommandCompletedTasks().values())
                     completed += n;
-                System.out.printf("%-25s%10s%10s%15s%n", "Commands", "n/a", pending, completed);
+                dropped = 0;
+                for (long n : ms.getCommandDroppedTasks().values())
+                    dropped += n;
+                System.out.printf("%-25s%10s%10s%15s%10s%n", "Commands", "n/a", pending,
completed, dropped);
 
                 pending = 0;
                 for (int n : ms.getResponsePendingTasks().values())
@@ -727,7 +732,7 @@ public class NodeTool
                 completed = 0;
                 for (long n : ms.getResponseCompletedTasks().values())
                     completed += n;
-                System.out.printf("%-25s%10s%10s%15s%n", "Responses", "n/a", pending, completed);
+                System.out.printf("%-25s%10s%10s%15s%10s%n", "Responses", "n/a", pending,
completed, "n/a");
             }
         }
     }


Mime
View raw message