Author: j16sdiz
Date: 2008-09-11 15:13:41 +0000 (Thu, 11 Sep 2008)
New Revision: 22605

Modified:
   trunk/freenet/src/freenet/l10n/freenet.l10n.en.properties
   trunk/freenet/src/freenet/node/Node.java
Log:
set it to -1 for default value

Modified: trunk/freenet/src/freenet/l10n/freenet.l10n.en.properties
===================================================================
--- trunk/freenet/src/freenet/l10n/freenet.l10n.en.properties   2008-09-11 
15:13:18 UTC (rev 22604)
+++ trunk/freenet/src/freenet/l10n/freenet.l10n.en.properties   2008-09-11 
15:13:41 UTC (rev 22605)
@@ -715,7 +715,7 @@
 Node.storeType=Store type (LEAVE THIS ALONE)
 Node.storeTypeLong=Datastore type. Currently this can be salt-hash 
(EXPERIMENTIAL, use a salted on-disk hashtable with bloom filter), bdb-index 
(STABLE, use a BerkeleyDBFreenetStore to store the index, and keep the data in 
files on disk), or ram (FOR TESTING ONLY, keep the index and the data in RAM). 
Only use ram if you know what you are doing and have enough RAM to store all 
your data (and note it will not be saved on shutdown)! Changes will not take 
effect until Freenet has been restarted.
 Node.storeBloomFilterSize=Bloom filter size (total) in bytes
-Node.storeBloomFilterSizeLong=Bloom filter size (total) in bytes. Usually 
1/2048th the size of data store is more than enough. Set this to zero to 
disable bloom filter.
+Node.storeBloomFilterSizeLong=Bloom filter size (total) in bytes. Usually 
1/2048th the size of data store is more than enough. Set this to zero to 
disable bloom filter. Set this to -1 to reset to default.
 Node.storeBloomFilterCounting=Use counting bloom filter?
 Node.storeBloomFilterCountingLong=Use 2-bit counting bloom filter? (don't 
touch this unless you know what you are doing) 
 Node.swapRInterval=Swap request send interval (ms)

Modified: trunk/freenet/src/freenet/node/Node.java
===================================================================
--- trunk/freenet/src/freenet/node/Node.java    2008-09-11 15:13:18 UTC (rev 
22604)
+++ trunk/freenet/src/freenet/node/Node.java    2008-09-11 15:13:41 UTC (rev 
22605)
@@ -1521,7 +1521,7 @@

                maxTotalKeys = maxTotalDatastoreSize / sizePerKey;

-               nodeConfig.register("storeBloomFilterSize", (int) 
Math.min(maxTotalDatastoreSize / 2048, 268435456), sortOrder++, true, false, 
"Node.storeBloomFilterSize",
+               nodeConfig.register("storeBloomFilterSize", -1, sortOrder++, 
true, false, "Node.storeBloomFilterSize",
                        "Node.storeBloomFilterSizeLong", new IntCallback() {
                                private Integer cachedBloomFilterSize;

@@ -1545,6 +1545,8 @@
                        });

                storeBloomFilterSize = 
nodeConfig.getInt("storeBloomFilterSize");
+               if (storeBloomFilterSize == -1) 
+                       storeBloomFilterSize = (int) 
Math.min(maxTotalDatastoreSize / 2048, 268435456);

                nodeConfig.register("storeBloomFilterCounting", true, 
sortOrder++, true, false,
                        "Node.storeBloomFilterCounting", 
"Node.storeBloomFilterCountingLong", new BooleanCallback() {


Reply via email to