cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r1163205 - in /cassandra/branches/cassandra-0.8: CHANGES.txt src/java/org/apache/cassandra/utils/BloomCalculations.java src/java/org/apache/cassandra/utils/BloomFilter.java
Date Tue, 30 Aug 2011 13:39:55 GMT
Author: jbellis
Date: Tue Aug 30 13:39:54 2011
New Revision: 1163205

URL: http://svn.apache.org/viewvc?rev=1163205&view=rev
Log:
update CHANGES for #3023 and #3044

Modified:
    cassandra/branches/cassandra-0.8/CHANGES.txt
    cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomCalculations.java
    cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomFilter.java

Modified: cassandra/branches/cassandra-0.8/CHANGES.txt
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/CHANGES.txt?rev=1163205&r1=1163204&r2=1163205&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/CHANGES.txt (original)
+++ cassandra/branches/cassandra-0.8/CHANGES.txt Tue Aug 30 13:39:54 2011
@@ -40,6 +40,9 @@
  * always hint counters (CASSANDRA-3099)
  * fix log4j initialization in EmbeddedCassandraService (CASSANDRA-2857)
  * fix corner cases in Range.differenceToFetch (CASSANDRA-3084)
+ * fix ip address String representation in the ring cache (CASSANDRA-3044)
+ * fix ring cache compatibility when mixing pre-0.8.4 nodes with post-
+   in the same cluster (CASSANDRA-3023)
 
 
 0.8.4

Modified: cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomCalculations.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomCalculations.java?rev=1163205&r1=1163204&r2=1163205&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomCalculations.java
(original)
+++ cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomCalculations.java
Tue Aug 30 13:39:54 2011
@@ -106,14 +106,21 @@ class BloomCalculations {
      * A wrapper class that holds two key parameters for a Bloom Filter: the
      * number of hash functions used, and the number of buckets per element used.
      */
-    public static class BloomSpecification {
+    public static class BloomSpecification
+    {
         final int K; // number of hash functions.
         final int bucketsPerElement;
 
-        public BloomSpecification(int k, int bucketsPerElement) {
+        public BloomSpecification(int k, int bucketsPerElement)
+        {
             K = k;
             this.bucketsPerElement = bucketsPerElement;
         }
+
+        public String toString()
+        {
+            return String.format("BloomSpecification(K=%d, bucketsPerElement=%d)", K, bucketsPerElement);
+        }
     }
 
     /**

Modified: cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomFilter.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomFilter.java?rev=1163205&r1=1163204&r2=1163205&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomFilter.java
(original)
+++ cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/BloomFilter.java
Tue Aug 30 13:39:54 2011
@@ -70,6 +70,7 @@ public class BloomFilter extends Filter
                                       numElements, bucketsPerElement, targetBucketsPerElem));
         }
         BloomCalculations.BloomSpecification spec = BloomCalculations.computeBloomSpec(bucketsPerElement);
+        logger.debug("Creating bloom filter for {} elements and spec {}", numElements, spec);
         return new BloomFilter(spec.K, bucketsFor(numElements, spec.bucketsPerElement));
     }
 



Mime
View raw message