forked from I2P_Developers/i2p.i2p
placeholder for overload detection
This commit is contained in:
@ -47,6 +47,10 @@ public class HandleTunnelCreateMessageJob extends JobImpl {
|
|||||||
|
|
||||||
public void runJob() {
|
public void runJob() {
|
||||||
if (_log.shouldLog(Log.DEBUG)) _log.debug("Handling tunnel create");
|
if (_log.shouldLog(Log.DEBUG)) _log.debug("Handling tunnel create");
|
||||||
|
if (isOverloaded()) {
|
||||||
|
sendReply(false);
|
||||||
|
return;
|
||||||
|
}
|
||||||
TunnelInfo info = new TunnelInfo(_context);
|
TunnelInfo info = new TunnelInfo(_context);
|
||||||
info.setConfigurationKey(_message.getConfigurationKey());
|
info.setConfigurationKey(_message.getConfigurationKey());
|
||||||
info.setEncryptionKey(_message.getTunnelKey());
|
info.setEncryptionKey(_message.getTunnelKey());
|
||||||
@ -78,6 +82,11 @@ public class HandleTunnelCreateMessageJob extends JobImpl {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private boolean isOverloaded() {
|
||||||
|
// hmmm....
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
private class TestJob extends JobImpl {
|
private class TestJob extends JobImpl {
|
||||||
private TunnelInfo _target;
|
private TunnelInfo _target;
|
||||||
public TestJob(TunnelInfo target) {
|
public TestJob(TunnelInfo target) {
|
||||||
|
Reference in New Issue
Block a user