* 2006-04-05 0.6.1.14 released
This commit is contained in:
@ -14,8 +14,8 @@ package net.i2p;
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class CoreVersion {
|
public class CoreVersion {
|
||||||
public final static String ID = "$Revision: 1.55 $ $Date: 2006/02/27 14:05:41 $";
|
public final static String ID = "$Revision: 1.56 $ $Date: 2006/03/26 18:23:49 $";
|
||||||
public final static String VERSION = "0.6.1.13";
|
public final static String VERSION = "0.6.1.14";
|
||||||
|
|
||||||
public static void main(String args[]) {
|
public static void main(String args[]) {
|
||||||
System.out.println("I2P Core version: " + VERSION);
|
System.out.println("I2P Core version: " + VERSION);
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
$Id: history.txt,v 1.444 2006/04/04 07:20:39 jrandom Exp $
|
$Id: history.txt,v 1.445 2006/04/04 23:40:04 jrandom Exp $
|
||||||
|
|
||||||
|
* 2006-04-05 0.6.1.14 released
|
||||||
|
|
||||||
2006-04-05 jrandom
|
2006-04-05 jrandom
|
||||||
* Cut down on the time that we allow a tunnel creation request to sit by
|
* Cut down on the time that we allow a tunnel creation request to sit by
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<i2p.news date="$Date: 2006/02/27 14:05:41 $">
|
<i2p.news date="$Date: 2006/03/26 18:23:54 $">
|
||||||
<i2p.release version="0.6.1.13" date="2006/03/26" minVersion="0.6"
|
<i2p.release version="0.6.1.14" date="2006/04/05" minVersion="0.6"
|
||||||
anonurl="http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/i2p/i2pupdate.sud"
|
anonurl="http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/i2p/i2pupdate.sud"
|
||||||
publicurl="http://dev.i2p.net/i2p/i2pupdate.sud"
|
publicurl="http://dev.i2p.net/i2p/i2pupdate.sud"
|
||||||
anonannouncement="http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/pipermail/i2p/2005-September/000878.html"
|
anonannouncement="http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/pipermail/i2p/2005-September/000878.html"
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
<info>
|
<info>
|
||||||
<appname>i2p</appname>
|
<appname>i2p</appname>
|
||||||
<appversion>0.6.1.13</appversion>
|
<appversion>0.6.1.14</appversion>
|
||||||
<authors>
|
<authors>
|
||||||
<author name="I2P" email="support@i2p.net"/>
|
<author name="I2P" email="support@i2p.net"/>
|
||||||
</authors>
|
</authors>
|
||||||
|
10
news.xml
10
news.xml
@ -1,5 +1,5 @@
|
|||||||
<i2p.news date="$Date: 2006/03/28 21:09:23 $">
|
<i2p.news date="$Date: 2006/04/04 22:06:00 $">
|
||||||
<i2p.release version="0.6.1.13" date="2006/03/26" minVersion="0.6"
|
<i2p.release version="0.6.1.14" date="2006/04/05" minVersion="0.6"
|
||||||
anonurl="http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/i2p/i2pupdate.sud"
|
anonurl="http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/i2p/i2pupdate.sud"
|
||||||
publicurl="http://dev.i2p.net/i2p/i2pupdate.sud"
|
publicurl="http://dev.i2p.net/i2p/i2pupdate.sud"
|
||||||
anonannouncement="http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/pipermail/i2p/2005-September/000878.html"
|
anonannouncement="http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/pipermail/i2p/2005-September/000878.html"
|
||||||
@ -10,10 +10,8 @@
|
|||||||
anonlogs="http://i2p/Nf3ab-ZFkmI-LyMt7GjgT-jfvZ3zKDl0L96pmGQXF1B82W2Bfjf0n7~288vafocjFLnQnVcmZd~-p0-Oolfo9aW2Rm-AhyqxnxyLlPBqGxsJBXjPhm1JBT4Ia8FB-VXt0BuY0fMKdAfWwN61-tj4zIcQWRxv3DFquwEf035K~Ra4SWOqiuJgTRJu7~o~DzHVljVgWIzwf8Z84cz0X33pv-mdG~~y0Bsc2qJVnYwjjR178YMcRSmNE0FVMcs6f17c6zqhMw-11qjKpY~EJfHYCx4lBWF37CD0obbWqTNUIbL~78vxqZRT3dgAgnLixog9nqTO-0Rh~NpVUZnoUi7fNR~awW5U3Cf7rU7nNEKKobLue78hjvRcWn7upHUF45QqTDuaM3yZa7OsjbcH-I909DOub2Q0Dno6vIwuA7yrysccN1sbnkwZbKlf4T6~iDdhaSLJd97QCyPOlbyUfYy9QLNExlRqKgNVJcMJRrIual~Lb1CLbnzt0uvobM57UpqSAAAA/meeting141"
|
anonlogs="http://i2p/Nf3ab-ZFkmI-LyMt7GjgT-jfvZ3zKDl0L96pmGQXF1B82W2Bfjf0n7~288vafocjFLnQnVcmZd~-p0-Oolfo9aW2Rm-AhyqxnxyLlPBqGxsJBXjPhm1JBT4Ia8FB-VXt0BuY0fMKdAfWwN61-tj4zIcQWRxv3DFquwEf035K~Ra4SWOqiuJgTRJu7~o~DzHVljVgWIzwf8Z84cz0X33pv-mdG~~y0Bsc2qJVnYwjjR178YMcRSmNE0FVMcs6f17c6zqhMw-11qjKpY~EJfHYCx4lBWF37CD0obbWqTNUIbL~78vxqZRT3dgAgnLixog9nqTO-0Rh~NpVUZnoUi7fNR~awW5U3Cf7rU7nNEKKobLue78hjvRcWn7upHUF45QqTDuaM3yZa7OsjbcH-I909DOub2Q0Dno6vIwuA7yrysccN1sbnkwZbKlf4T6~iDdhaSLJd97QCyPOlbyUfYy9QLNExlRqKgNVJcMJRrIual~Lb1CLbnzt0uvobM57UpqSAAAA/meeting141"
|
||||||
publiclogs="http://www.i2p.net/meeting141" />
|
publiclogs="http://www.i2p.net/meeting141" />
|
||||||
•
|
•
|
||||||
2006-03-26:
|
2006-04-05: 0.6.1.14 released with important tunnel reliability, ssu, and peer
|
||||||
<a href="http://dev.i2p/pipermail/i2p/2006-March/001272.html">0.6.1.13 released</a>
|
selection fixes.
|
||||||
with improvements to load balancing, NetDB operation, new graphs and multiple fixes.
|
|
||||||
Upgrading highly recommended.
|
|
||||||
<br>
|
<br>
|
||||||
•
|
•
|
||||||
2006-04-04:
|
2006-04-04:
|
||||||
|
@ -44,9 +44,9 @@ public class DatabaseLookupMessage extends I2NPMessageImpl {
|
|||||||
}
|
}
|
||||||
public DatabaseLookupMessage(I2PAppContext context, boolean locallyCreated) {
|
public DatabaseLookupMessage(I2PAppContext context, boolean locallyCreated) {
|
||||||
super(context);
|
super(context);
|
||||||
setSearchKey(null);
|
//setSearchKey(null);
|
||||||
setFrom(null);
|
//setFrom(null);
|
||||||
setDontIncludePeers(null);
|
//setDontIncludePeers(null);
|
||||||
|
|
||||||
context.statManager().createRateStat("router.throttleNetDbDoSSend", "How many netDb lookup messages we are sending during a period with a DoS detected", "Throttle", new long[] { 60*1000, 10*60*1000, 60*60*1000, 24*60*60*1000 });
|
context.statManager().createRateStat("router.throttleNetDbDoSSend", "How many netDb lookup messages we are sending during a period with a DoS detected", "Throttle", new long[] { 60*1000, 10*60*1000, 60*60*1000, 24*60*60*1000 });
|
||||||
|
|
||||||
|
@ -290,7 +290,11 @@ public abstract class I2NPMessageImpl extends DataStructureImpl implements I2NPM
|
|||||||
|
|
||||||
public void readMessage(byte data[], int offset, int dataSize, int type, I2NPMessageHandler handler) throws I2NPMessageException, IOException {
|
public void readMessage(byte data[], int offset, int dataSize, int type, I2NPMessageHandler handler) throws I2NPMessageException, IOException {
|
||||||
// ignore the handler (overridden in subclasses if necessary
|
// ignore the handler (overridden in subclasses if necessary
|
||||||
readMessage(data, offset, dataSize, type);
|
try {
|
||||||
|
readMessage(data, offset, dataSize, type);
|
||||||
|
} catch (IllegalArgumentException iae) {
|
||||||
|
throw new I2NPMessageException("Error reading the message", iae);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -313,21 +317,23 @@ public abstract class I2NPMessageImpl extends DataStructureImpl implements I2NPM
|
|||||||
return msg;
|
return msg;
|
||||||
}
|
}
|
||||||
|
|
||||||
long expiration = DataHelper.fromLong(buffer, offset, 4) * 1000; // seconds
|
|
||||||
offset += 4;
|
|
||||||
int dataSize = len - 1 - 4;
|
|
||||||
try {
|
try {
|
||||||
|
long expiration = DataHelper.fromLong(buffer, offset, 4) * 1000; // seconds
|
||||||
|
offset += 4;
|
||||||
|
int dataSize = len - 1 - 4;
|
||||||
msg.readMessage(buffer, offset, dataSize, type, handler);
|
msg.readMessage(buffer, offset, dataSize, type, handler);
|
||||||
msg.setMessageExpiration(expiration);
|
msg.setMessageExpiration(expiration);
|
||||||
msg.read();
|
msg.read();
|
||||||
return msg;
|
return msg;
|
||||||
} catch (IOException ioe) {
|
} catch (IOException ioe) {
|
||||||
throw new I2NPMessageException("IO error reading raw message", ioe);
|
throw new I2NPMessageException("IO error reading raw message", ioe);
|
||||||
|
} catch (IllegalArgumentException iae) {
|
||||||
|
throw new I2NPMessageException("Corrupt message (negative expiration)", iae);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void verifyUnwritten() {
|
protected void verifyUnwritten() {
|
||||||
// if (_written) throw new RuntimeException("Already written");
|
if (_written) throw new RuntimeException("Already written");
|
||||||
}
|
}
|
||||||
protected void written() { _written = true; }
|
protected void written() { _written = true; }
|
||||||
protected void read() { _read = true; }
|
protected void read() { _read = true; }
|
||||||
|
@ -15,9 +15,9 @@ import net.i2p.CoreVersion;
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class RouterVersion {
|
public class RouterVersion {
|
||||||
public final static String ID = "$Revision: 1.384 $ $Date: 2006/04/03 05:07:25 $";
|
public final static String ID = "$Revision: 1.385 $ $Date: 2006/04/04 23:40:10 $";
|
||||||
public final static String VERSION = "0.6.1.13";
|
public final static String VERSION = "0.6.1.14";
|
||||||
public final static long BUILD = 5;
|
public final static long BUILD = 0;
|
||||||
public static void main(String args[]) {
|
public static void main(String args[]) {
|
||||||
System.out.println("I2P Router version: " + VERSION + "-" + BUILD);
|
System.out.println("I2P Router version: " + VERSION + "-" + BUILD);
|
||||||
System.out.println("Router ID: " + RouterVersion.ID);
|
System.out.println("Router ID: " + RouterVersion.ID);
|
||||||
|
@ -129,6 +129,7 @@ public class FloodfillNetworkDatabaseFacade extends KademliaNetworkDatabaseFacad
|
|||||||
*/
|
*/
|
||||||
SearchJob search(Hash key, Job onFindJob, Job onFailedLookupJob, long timeoutMs, boolean isLease) {
|
SearchJob search(Hash key, Job onFindJob, Job onFailedLookupJob, long timeoutMs, boolean isLease) {
|
||||||
//if (true) return super.search(key, onFindJob, onFailedLookupJob, timeoutMs, isLease);
|
//if (true) return super.search(key, onFindJob, onFailedLookupJob, timeoutMs, isLease);
|
||||||
|
if (key == null) throw new IllegalArgumentException("searchin for nothin, eh?");
|
||||||
boolean isNew = true;
|
boolean isNew = true;
|
||||||
FloodSearchJob searchJob = null;
|
FloodSearchJob searchJob = null;
|
||||||
synchronized (_activeFloodQueries) {
|
synchronized (_activeFloodQueries) {
|
||||||
|
@ -156,8 +156,11 @@ public class MessageReceiver {
|
|||||||
+ " raw: " + Base64.encode(fragments[i].getData()) + ")");
|
+ " raw: " + Base64.encode(fragments[i].getData()) + ")");
|
||||||
off += fragments[i].getValid();
|
off += fragments[i].getValid();
|
||||||
}
|
}
|
||||||
if (off != state.getCompleteSize())
|
if (off != state.getCompleteSize()) {
|
||||||
_log.error("Hmm, offset of the fragments = " + off + " while the state says " + state.getCompleteSize());
|
if (_log.shouldLog(Log.WARN))
|
||||||
|
_log.warn("Hmm, offset of the fragments = " + off + " while the state says " + state.getCompleteSize());
|
||||||
|
return null;
|
||||||
|
}
|
||||||
if (_log.shouldLog(Log.DEBUG))
|
if (_log.shouldLog(Log.DEBUG))
|
||||||
_log.debug("Raw byte array for " + state.getMessageId() + ": " + Base64.encode(buf.getData(), 0, state.getCompleteSize()));
|
_log.debug("Raw byte array for " + state.getMessageId() + ": " + Base64.encode(buf.getData(), 0, state.getCompleteSize()));
|
||||||
I2NPMessage m = I2NPMessageImpl.fromRawByteArray(_context, buf.getData(), 0, state.getCompleteSize(), handler);
|
I2NPMessage m = I2NPMessageImpl.fromRawByteArray(_context, buf.getData(), 0, state.getCompleteSize(), handler);
|
||||||
|
@ -47,8 +47,7 @@ public class OutboundMessageState {
|
|||||||
public boolean initialize(OutNetMessage msg) {
|
public boolean initialize(OutNetMessage msg) {
|
||||||
if (msg == null) return false;
|
if (msg == null) return false;
|
||||||
try {
|
try {
|
||||||
initialize(msg, msg.getMessage(), null);
|
return initialize(msg, msg.getMessage(), null);
|
||||||
return true;
|
|
||||||
} catch (OutOfMemoryError oom) {
|
} catch (OutOfMemoryError oom) {
|
||||||
throw oom;
|
throw oom;
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
@ -62,8 +61,7 @@ public class OutboundMessageState {
|
|||||||
return false;
|
return false;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
initialize(null, msg, peer);
|
return initialize(null, msg, peer);
|
||||||
return true;
|
|
||||||
} catch (OutOfMemoryError oom) {
|
} catch (OutOfMemoryError oom) {
|
||||||
throw oom;
|
throw oom;
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
@ -77,8 +75,7 @@ public class OutboundMessageState {
|
|||||||
return false;
|
return false;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
initialize(m, msg, null);
|
return initialize(m, msg, null);
|
||||||
return true;
|
|
||||||
} catch (OutOfMemoryError oom) {
|
} catch (OutOfMemoryError oom) {
|
||||||
throw oom;
|
throw oom;
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
@ -87,7 +84,7 @@ public class OutboundMessageState {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void initialize(OutNetMessage m, I2NPMessage msg, PeerState peer) {
|
private boolean initialize(OutNetMessage m, I2NPMessage msg, PeerState peer) {
|
||||||
_message = m;
|
_message = m;
|
||||||
_peer = peer;
|
_peer = peer;
|
||||||
if (_messageBuf != null) {
|
if (_messageBuf != null) {
|
||||||
@ -99,17 +96,24 @@ public class OutboundMessageState {
|
|||||||
int size = msg.getRawMessageSize();
|
int size = msg.getRawMessageSize();
|
||||||
if (size > _messageBuf.getData().length)
|
if (size > _messageBuf.getData().length)
|
||||||
throw new IllegalArgumentException("Size too large! " + size + " in " + msg);
|
throw new IllegalArgumentException("Size too large! " + size + " in " + msg);
|
||||||
int len = msg.toRawByteArray(_messageBuf.getData());
|
try {
|
||||||
_messageBuf.setValid(len);
|
int len = msg.toRawByteArray(_messageBuf.getData());
|
||||||
_messageId = msg.getUniqueId();
|
_messageBuf.setValid(len);
|
||||||
|
_messageId = msg.getUniqueId();
|
||||||
_startedOn = _context.clock().now();
|
|
||||||
_nextSendTime = _startedOn;
|
_startedOn = _context.clock().now();
|
||||||
_expiration = _startedOn + 10*1000;
|
_nextSendTime = _startedOn;
|
||||||
//_expiration = msg.getExpiration();
|
_expiration = _startedOn + 10*1000;
|
||||||
|
//_expiration = msg.getExpiration();
|
||||||
if (_log.shouldLog(Log.DEBUG))
|
|
||||||
_log.debug("Raw byte array for " + _messageId + ": " + Base64.encode(_messageBuf.getData(), 0, len));
|
if (_log.shouldLog(Log.DEBUG))
|
||||||
|
_log.debug("Raw byte array for " + _messageId + ": " + Base64.encode(_messageBuf.getData(), 0, len));
|
||||||
|
return true;
|
||||||
|
} catch (IllegalStateException ise) {
|
||||||
|
_cache.release(_messageBuf);
|
||||||
|
_messageBuf = null;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void releaseResources() {
|
public void releaseResources() {
|
||||||
|
@ -435,7 +435,7 @@ public class TunnelDispatcher implements Service {
|
|||||||
_context.statManager().addRateData("tunnel.dispatchInbound", 1, 0);
|
_context.statManager().addRateData("tunnel.dispatchInbound", 1, 0);
|
||||||
} else {
|
} else {
|
||||||
_context.messageHistory().droppedTunnelGatewayMessageUnknown(msg.getUniqueId(), msg.getTunnelId().getTunnelId());
|
_context.messageHistory().droppedTunnelGatewayMessageUnknown(msg.getUniqueId(), msg.getTunnelId().getTunnelId());
|
||||||
int level = (_context.router().getUptime() > 10*60*1000 ? Log.ERROR : Log.WARN);
|
int level = (_context.router().getUptime() > 10*60*1000 ? Log.WARN : Log.INFO);
|
||||||
if (_log.shouldLog(level))
|
if (_log.shouldLog(level))
|
||||||
_log.log(level, "no matching tunnel for id=" + msg.getTunnelId().getTunnelId()
|
_log.log(level, "no matching tunnel for id=" + msg.getTunnelId().getTunnelId()
|
||||||
+ ": gateway message expiring in "
|
+ ": gateway message expiring in "
|
||||||
|
Reference in New Issue
Block a user