2006-03-25 jrandom

* Added a simple purge and ban of syndie authors, shown as the
      "Purge and ban" button on the addressbook for authors that are already
      on the ignore list.  All of their entries and metadata are deleted from
      the archive, and the are transparently filtered from any remote
      syndication (so no user on the syndie instance will pull any new posts
      from them)
    * More strict tunnel join throtting when congested
This commit is contained in:
jrandom
2006-03-25 23:50:48 +00:00
committed by zzz
parent d489caa88c
commit b5c0d77c69
9 changed files with 116 additions and 18 deletions

View File

@ -238,6 +238,7 @@ class RouterThrottleImpl implements RouterThrottle {
}
private static final int DEFAULT_MESSAGES_PER_TUNNEL_ESTIMATE = 600; // 1KBps
private static final int MIN_AVAILABLE_BPS = 4*1024; // always leave at least 4KBps free when allowing
/**
* with bytesAllocated already accounted for across the numTunnels existing
@ -279,7 +280,7 @@ class RouterThrottleImpl implements RouterThrottle {
return true;
} else {
double probAllow = availBps / (allocatedBps + availBps);
boolean allow = _context.random().nextDouble() <= probAllow;
boolean allow = (availBps > MIN_AVAILABLE_BPS) && (_context.random().nextDouble() <= probAllow);
if (allow) {
if (_log.shouldLog(Log.INFO))
_log.info("Probabalistically allowing the tunnel w/ " + (pctFull*100d) + "% of our " + availBps

View File

@ -15,9 +15,9 @@ import net.i2p.CoreVersion;
*
*/
public class RouterVersion {
public final static String ID = "$Revision: 1.378 $ $Date: 2006/03/21 18:13:09 $";
public final static String ID = "$Revision: 1.379 $ $Date: 2006/03/24 15:53:30 $";
public final static String VERSION = "0.6.1.12";
public final static long BUILD = 16;
public final static long BUILD = 17;
public static void main(String args[]) {
System.out.println("I2P Router version: " + VERSION + "-" + BUILD);
System.out.println("Router ID: " + RouterVersion.ID);