cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject svn commit: r1163782 - /cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/service/GCInspector.java
Date Wed, 31 Aug 2011 20:04:51 GMT
Author: jake
Date: Wed Aug 31 20:04:51 2011
New Revision: 1163782

URL: http://svn.apache.org/viewvc?rev=1163782&view=rev
Log:
Fix div by zero error take two
patch by tjake; reviewed by jbellis for CASSANDRA-3076

Modified:
    cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/service/GCInspector.java

Modified: cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/service/GCInspector.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/service/GCInspector.java?rev=1163782&r1=1163781&r2=1163782&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/service/GCInspector.java
(original)
+++ cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/service/GCInspector.java
Wed Aug 31 20:04:51 2011
@@ -103,10 +103,12 @@ public class GCInspector
 
             Long previousCount = gccounts.get(gc.getName());
             Long count = gc.getCollectionCount();
-            if (count == 0)
-                continue;
+            
             if (previousCount == null)
-                previousCount = 0L;
+                previousCount = 0L;           
+            if (count == previousCount)
+                continue;
+            
             gccounts.put(gc.getName(), count);
 
             MemoryUsage mu = membean.getHeapMemoryUsage();



Mime
View raw message