Update of /cvsroot/freenet/freenet/src/freenet/node/states/FNP
In directory sc8-pr-cvs1:/tmp/cvs-serv30192/src/freenet/node/states/FNP
Modified Files:
NewRequest.java NewDataRequest.java
Log Message:
6349:
Major debugging on NGRouting recent changes.
Add diagnostic startedRequestHTL, use it to make the maintenance requests use typical
HTLs and therefore not introduce bias.
Transients should not accept requests; include a flag that they are transient in their
references, and don't put transients into the routing table.
Reinstate probabilistic referencing in NGRouting - under strict conditions (40 working
non-backed off nodes out of 50). New param: minRTNodesPRef. Move shouldReference to RT.
Accept out of band references if less than 40 out of 50 nodes in RT and not backed off.
Add NGRT.countUnbackedOffNodes()
Fix pessimistic estimators initializing pDNF to min pDNF rather than max pDNF if no
key to start from.
Increase estimators Version to 3 to avoid pollution by estimators intted to 0.0 pDNF
because of that bug.
Initialize pSearchFailed pessimistically to 1.0.
Logging.
Index: NewRequest.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/node/states/FNP/NewRequest.java,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -w -r1.47 -r1.48
--- NewRequest.java 21 Nov 2003 00:26:20 -0000 1.47
+++ NewRequest.java 22 Nov 2003 17:56:01 -0000 1.48
@@ -69,7 +69,18 @@
throw new RequestAbortException(null);
}
+
try {
+ if(n.isTransient()) {
+ String reason = "Transient node";
+ Core.logger.log(this,
+ "Rejecting query from host (we are transient):
"+reason,
+ Logger.NORMAL);
+ Message m = new QueryRejected(id, mo.hopsToLive,
+ reason, mo.otherFields);
+ n.sendMessageAsync(m, ref, PeerHandler.EXPENDABLE,
+ Core.hopTime(1), null);
+ }
// enforce version aloofness
String vers = mo.getSource().getVersion();
if (vers != null && !Version.checkGoodVersion(vers)) {
Index: NewDataRequest.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/node/states/FNP/NewDataRequest.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -w -r1.9 -r1.10
--- NewDataRequest.java 21 Nov 2003 21:12:44 -0000 1.9
+++ NewDataRequest.java 22 Nov 2003 17:56:01 -0000 1.10
@@ -42,6 +42,8 @@
RequestInitiator ri = new RequestInitiator(id,
drmo.getReceivedTime());
Node.recentKeys.add(drmo.searchKey);
+ Core.diagnostics.occurrenceContinuous("startedRequestHTL",
+ drmo.hopsToLive);
Pending p = new DataPending(id, (int) drmo.hopsToLive,
drmo.searchKey, origRec, ft, ri, false);
Core.diagnostics.occurrenceCounting("incomingRequests", 1);
_______________________________________________
cvs mailing list
[EMAIL PROTECTED]
http://dodo.freenetproject.org/cgi-bin/mailman/listinfo/cvs