Skip to content

Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance

- fix for http://forum.yacy-websuche.de/viewtopic.php?f=5&t=14&p=137#p137 - fix for missing restart script in ant built target - removed some more synchronization for size() operations - removed blocking statement on search page

orbiter1a45ecb3566c
diff --git a/build.xml b/build.xml
index 697e913e7..5c3734e4a 100644
--- a/build.xml
+++ b/build.xml
@@ -472,6 +472,7 @@
<include name="startYACY.sh"/>
<include name="stopYACY.sh"/>
<include name="killYACY.sh"/>
+ <include name="restart.sh"/>
<include name="startYACY.command"/>
<include name="stopYACY.command"/>
</fileset>
diff --git a/htroot/index.html b/htroot/index.html
index 7bdbba296..9b5685430 100644
--- a/htroot/index.html
+++ b/htroot/index.html
@@ -115,7 +115,7 @@
</tr>
</table>
#(/searchoptions)#
- <p>This peer holds #[links]# URLs of #[total-links]# in the known network.</p>
+ <p>This peer holds #[links]# URLs</p>
</form>
#(searchoptions)#::
<p>
diff --git a/htroot/index.java b/htroot/index.java
index aff14053f..577319b6c 100644
--- a/htroot/index.java
+++ b/htroot/index.java
@@ -105,11 +105,11 @@ public class index {
if (cds.equals("image")) contentdom = plasmaSearchQuery.CONTENTDOM_IMAGE;
if (cds.equals("app")) contentdom = plasmaSearchQuery.CONTENTDOM_APP;
- long mylinks = 0;
+ //long mylinks = 0;
try {
- prop.put("links", groupDigits(mylinks = Long.parseLong(yacyCore.seedDB.mySeed.get(yacySeed.LCOUNT, "0"))));
+ prop.put("links", groupDigits(/*mylinks = */Long.parseLong(yacyCore.seedDB.mySeed.get(yacySeed.LCOUNT, "0"))));
} catch (NumberFormatException e) { prop.put("links", "0"); }
- prop.put("total-links", groupDigits(mylinks + yacyCore.seedDB.countActiveURL()));
+ //prop.put("total-links", groupDigits(mylinks + yacyCore.seedDB.countActiveURL())); // extremely time-intensive!
// we create empty entries for template strings
String promoteSearchPageGreeting = env.getConfig("promoteSearchPageGreeting", "");
diff --git a/source/de/anomic/kelondro/kelondroStack.java b/source/de/anomic/kelondro/kelondroStack.java
index f2bb7b46e..ef826412c 100644
--- a/source/de/anomic/kelondro/kelondroStack.java
+++ b/source/de/anomic/kelondro/kelondroStack.java
@@ -138,7 +138,7 @@ public final class kelondroStack extends kelondroRecords {
}
}
- public synchronized int size() {
+ public int size() {
return super.size();
}
diff --git a/source/de/anomic/plasma/plasmaCrawlBalancer.java b/source/de/anomic/plasma/plasmaCrawlBalancer.java
index d840f4478..bb3d3e069 100644
--- a/source/de/anomic/plasma/plasmaCrawlBalancer.java
+++ b/source/de/anomic/plasma/plasmaCrawlBalancer.java
@@ -190,7 +190,7 @@ public class plasmaCrawlBalancer {
}
}
- public synchronized int size() {
+ public int size() {
int componentsize = urlFileStack.size() + urlRAMStack.size() + sizeDomainStacks();
if (componentsize != urlFileIndex.size()) {
// here is urlIndexFile.size() always smaller. why?
diff --git a/source/de/anomic/yacy/yacyVersion.java b/source/de/anomic/yacy/yacyVersion.java
index 519ab78b2..784f99bb4 100644
--- a/source/de/anomic/yacy/yacyVersion.java
+++ b/source/de/anomic/yacy/yacyVersion.java
@@ -265,7 +265,7 @@ public final class yacyVersion implements Comparator, Comparable {
}
public static void writeDeployScript(String release) {
- byte[] script = ("tar xfz " + release + ";cp -Rf yacy/* ../../;rm -Rf yacy;cd ../../;startYACY.sh").getBytes();
+ byte[] script = ("cd `dirname $0`;while [ -e ../yacy.running ]; do sleep 1;done;tar xfz " + release + ";cp -Rf yacy/* ../../;rm -Rf yacy;cd ../../;startYACY.sh").getBytes();
}
}