Update of /cvsroot/freenet/freenet/src/freenet/config
In directory sc8-pr-cvs1:/tmp/cvs-serv8807/src/freenet/config
Modified Files:
Tag: stable
Config.java NormalOption.java Option.java Params.java
Setup.java
Log Message:
5030: Merge minor(ish) changes from unstable:
Open Connections infolet
Minor implementation changes on normal mode
Show total bytes transmitted/received so far
Much new information on the PeerHandler mode
Fixed tons of eclipse warnings (almost all are style issues, not functional changes -
relating to logger and imports mostly). Remove deprecated FieldSet.add(String,String).
Update TestLocalNIOInterface to current API
Make 5029 mandatory (it can't connect to us anyway, only vice versa).
If incoming HTL is 25, 50% chance of not decrementing it, so we have some plausible
deniability when we send out an HTL 25 request (the client level HTL perturb mechanism
is insufficient although useful).
Don't use seednodes with no physical address.
Use our own URLEncoder/URLDecoder's, catch the exceptions. We were using java's, which
are deprecated.
Add support for deprecated options. These will be read form config file and handled,
but will not be written to it by --config. Currently bandwidthLimit and
averageBandwidthLimit are in this category. Separate code logs an error when these are
set.
Change the way bandwidthLimit set but others not set, to prevent it from constantly
getting 100% load due to bandwidth limit (0!) exceeded.
Set priority of entropy thread to MIN.
Remove old datastore code, GOOD RIDDENS!
Add a memory usage test for the Failure Table
Increase size of failure table to 20,000 (from 2,000).
Don't show the key request form in simple mode on the default infolet.
Major refactoring of HTML reporting, writing to disk, in NGRouting estimators.
Relative times in (for example) ?date= in fproxy: ?date=-1year gives the edition of a
DBR one year ago.
NIO refactoring (ASL.ChannelAttachmentPairQueue).
Logging.
Index: Config.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/config/Config.java,v
retrieving revision 1.5.4.2.2.2
retrieving revision 1.5.4.2.2.3
diff -u -w -r1.5.4.2.2.2 -r1.5.4.2.2.3
--- Config.java 28 Oct 2003 20:20:29 -0000 1.5.4.2.2.2
+++ Config.java 1 Nov 2003 16:55:23 -0000 1.5.4.2.2.3
@@ -1,13 +1,13 @@
/* -*- Mode: java; c-basic-indent: 4; tab-width: 4 -*- */
package freenet.config;
-import freenet.support.Comparable;
-import freenet.support.sort.ArraySorter;
-import freenet.support.sort.QuickSorter;
import java.io.PrintStream;
import java.io.PrintWriter;
-import java.io.IOException;
-import java.util.*;
+import java.util.Enumeration;
+import java.util.Hashtable;
+
+import freenet.support.sort.ArraySorter;
+import freenet.support.sort.QuickSorter;
/** A registry of Options.
* @author tavin
@@ -147,6 +147,14 @@
((Option) options.get(name)).isExpert = isExpert;
}
+ /**
+ * Allows an option to be set as deprecated, meaning it will
+ * never be written, but will be read.
+ */
+ public void setDeprecated(String name, boolean isDeprecated) {
+ ((Option) options.get(name)).isDeprecated = isDeprecated;
+ }
+
/**
* Describes the argument(s) to the option.
*/
Index: NormalOption.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/config/NormalOption.java,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.1.2.1
diff -u -w -r1.1.4.1 -r1.1.4.1.2.1
--- NormalOption.java 14 Dec 2002 18:09:32 -0000 1.1.4.1
+++ NormalOption.java 1 Nov 2003 16:55:25 -0000 1.1.4.1.2.1
@@ -1,5 +1,4 @@
package freenet.config;
-import freenet.support.Comparable;
public class NormalOption extends Option {
Index: Option.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/config/Option.java,v
retrieving revision 1.2.4.1.2.3
retrieving revision 1.2.4.1.2.4
diff -u -w -r1.2.4.1.2.3 -r1.2.4.1.2.4
--- Option.java 28 Oct 2003 20:20:29 -0000 1.2.4.1.2.3
+++ Option.java 1 Nov 2003 16:55:25 -0000 1.2.4.1.2.4
@@ -9,6 +9,7 @@
Class defaultClass;
Object defaultValue;
boolean isExpert = false;
+ boolean isDeprecated = false;
int sortOrder;
String argDesc;
Index: Params.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/config/Params.java,v
retrieving revision 1.3.4.5.2.2
retrieving revision 1.3.4.5.2.3
diff -u -w -r1.3.4.5.2.2 -r1.3.4.5.2.3
--- Params.java 2 Aug 2003 02:36:18 -0000 1.3.4.5.2.2
+++ Params.java 1 Nov 2003 16:55:26 -0000 1.3.4.5.2.3
@@ -1,11 +1,19 @@
package freenet.config;
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.util.Enumeration;
+import java.util.Hashtable;
+import java.util.StringTokenizer;
+import java.util.Vector;
+
import freenet.FieldSet;
-import freenet.support.*;
-import freenet.support.io.*;
-import freenet.Core;
-import java.util.*;
-import java.io.*;
+import freenet.support.io.CommentedBufferedReader;
/**
* Reads and stores Freenet parameters
Index: Setup.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/config/Setup.java,v
retrieving revision 1.4.4.1.2.4
retrieving revision 1.4.4.1.2.5
diff -u -w -r1.4.4.1.2.4 -r1.4.4.1.2.5
--- Setup.java 28 Oct 2003 20:20:30 -0000 1.4.4.1.2.4
+++ Setup.java 1 Nov 2003 16:55:26 -0000 1.4.4.1.2.5
@@ -1,16 +1,25 @@
package freenet.config;
-import freenet.node.Node;
-import freenet.support.io.*;
-import freenet.support.*;
-import freenet.support.sort.*;
-import java.net.ServerSocket;
-import java.lang.reflect.Method;
-import java.io.*;
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.io.OutputStream;
+import java.io.PrintStream;
+import java.io.PrintWriter;
import java.text.DateFormat;
import java.util.Date;
-import java.util.Vector;
-import java.util.Enumeration;
+
+import freenet.node.Node;
+import freenet.support.ArrayBucket;
+import freenet.support.Bucket;
+import freenet.support.io.ReadInputStream;
+import freenet.support.sort.ArraySorter;
+import freenet.support.sort.QuickSorter;
/** Builds a configuration file from the options registered in Core.config
*/
@@ -441,6 +450,7 @@
};
}
+ if(opt.isDeprecated) return;
if (expert || !opt.isExpert) println("Setting: " + name);
comment(comment, opt.isExpert, out);
_______________________________________________
cvs mailing list
[EMAIL PROTECTED]
http://dodo.freenetproject.org/cgi-bin/mailman/listinfo/cvs