Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance
Java decentralizedintranet-searchintranet-search-enginep2pp2p-networkprivacyprivacy-protectionsearch-enginesearchenginewebweb-search-enginewebsearchwebseearch-engine
- fixed problem with thread dump if no arguments are given - rejecting peers that are older than 6 hours (not-seen during 6 hours) - 0.78, targeting 0.8 at the end of the week
orbiterc01d6f43e1d3
diff --git a/build.properties b/build.propertiesindex 2ea47c48d..55b41da10 100644--- a/build.properties+++ b/build.properties@@ -3,7 +3,7 @@ javacSource=1.5javacTarget=1.5# Release Configuration-releaseVersion=0.77+releaseVersion=0.78stdReleaseFile=yacy_v${releaseVersion}_${DSTAMP}_${releaseNr}.tar.gzembReleaseFile=yacy_emb_v${releaseVersion}_${DSTAMP}_${releaseNr}.tar.gzproReleaseFile=yacy_pro_v${releaseVersion}_${DSTAMP}_${releaseNr}.tar.gzdiff --git a/htroot/Network.java b/htroot/Network.javaindex 62a8c08f7..d8dde98d7 100644--- a/htroot/Network.java+++ b/htroot/Network.java@@ -381,7 +381,10 @@ public class Network {prop.putHTML(STR_TABLE_LIST + conCount + "_type_url", seed.get(yacySeed.SEEDLIST, "http://nowhere/"));final long lastseen = Math.abs((System.currentTimeMillis() - seed.getLastSeenUTC()) / 1000 / 60);- if (page == 2 || lastseen > 1440) { // Passive Peers should be passive, also Peers without contact greater than an day+ if (page == 1 && lastseen > 720) {+ continue;+ }+ if (page == 2 || (page == 1 && lastseen > 360)) { // Passive Peers should be passive, also Peers without contact greater than 6 hours// principal/senior/junior: red/red=offlineprop.put(STR_TABLE_LIST + conCount + "_type_direct", 2);} else {diff --git a/htroot/Threaddump_p.java b/htroot/Threaddump_p.javaindex eb7fcb067..4ecbfab6c 100644--- a/htroot/Threaddump_p.java+++ b/htroot/Threaddump_p.java@@ -56,8 +56,8 @@ public class Threaddump_p {final StringBuilder buffer = new StringBuilder(1000);- final boolean plain = post.get("plain", "false").equals("true");- final int sleep = post.getInt("sleep", 0); // a sleep before creation of a thread dump can be used for profiling+ final boolean plain = post != null && post.get("plain", "false").equals("true");+ final int sleep = (post == null) ? 0 : post.getInt("sleep", 0); // a sleep before creation of a thread dump can be used for profilingif (sleep > 0) try {Thread.sleep(sleep);} catch (final InterruptedException e) {}prop.put("dump", "1");// Thread dumpdiff --git a/htroot/env/templates/submenuViewLog.template b/htroot/env/templates/submenuViewLog.templateindex c68063d2c..5daf079c9 100644--- a/htroot/env/templates/submenuViewLog.template+++ b/htroot/env/templates/submenuViewLog.template@@ -3,6 +3,6 @@<ul class="SubMenu"><li><a href="/ViewLog_p.html" class="MenuItemLink lock">Server Log</a></li><li><a href="/LogStatistics_p.html" class="MenuItemLink lock">Log Statistics</a></li>- <li><a href="/Threaddump_p.html?createThreaddump=" class="MenuItemLink lock">Thread Dump</a></li>+ <li><a href="/Threaddump_p.html" class="MenuItemLink lock">Thread Dump</a></li></ul></div>\ No newline at end of filediff --git a/source/de/anomic/yacy/yacyPeerActions.java b/source/de/anomic/yacy/yacyPeerActions.javaindex 1f8839fde..40f78a8b3 100644--- a/source/de/anomic/yacy/yacyPeerActions.java+++ b/source/de/anomic/yacy/yacyPeerActions.java@@ -105,7 +105,7 @@ public class yacyPeerActions {ctimeUTC0 = nowUTC0Time;assert (seed.getLastSeenUTC() - ctimeUTC0 < 100);}- if (Math.abs(nowUTC0Time - ctimeUTC0) > 60 * 60 * 12 * 1000) {+ if (Math.abs(nowUTC0Time - ctimeUTC0) / 1000 / 60 > 60 * 6 ) {// the new connection is out-of-age, we reject the connectionif (yacyCore.log.isFine()) yacyCore.log.logFine("connect: rejecting out-dated peer '" + seed.getName() + "' from " + seed.getPublicAddress() + "; nowUTC0=" + nowUTC0Time + ", seedUTC0=" + ctimeUTC0 + ", TimeDiff=" + DateFormatter.formatInterval(Math.abs(nowUTC0Time - ctimeUTC0)));return false;