From 8c1a89cb3499dd5cb48d752abdf8b08bbd97db26 Mon Sep 17 00:00:00 2001 From: Michael Peter Christen Date: Wed, 8 Oct 2014 17:12:35 +0200 Subject: [PATCH] added another decoration flag to switch off network graphics in crawler monitor and index browser: decoration.grafics.linkstructure Please set this to false to remove the graphics from the interface. --- defaults/yacy.init | 2 ++ htroot/Crawler_p.java | 3 ++- htroot/HostBrowser.java | 2 +- source/net/yacy/search/SwitchboardConstants.java | 1 + 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/defaults/yacy.init b/defaults/yacy.init index d29352b55..b8e168308 100644 --- a/defaults/yacy.init +++ b/defaults/yacy.init @@ -1260,3 +1260,5 @@ crawler.userAgent.clienttimeout = 10000 # interface decorations decoration.audio = false +decoration.grafics.linkstructure = true + diff --git a/htroot/Crawler_p.java b/htroot/Crawler_p.java index 04e24886f..1f333286f 100644 --- a/htroot/Crawler_p.java +++ b/htroot/Crawler_p.java @@ -662,7 +662,8 @@ public class Crawler_p { prop.put("crawlProfilesShow", count == 0 ? 0 : 1); prop.put("crawlProfilesShow_linkstructure", 0); - if (count > 0) { + + if (count > 0 && sb.getConfigBool(SwitchboardConstants.DECORATION_GRAFICS_LINKSTRUCTURE, true)) { // collect the host names for 'wide' crawls which can be visualized boolean showLinkstructure = hosts.length() > 0 && !hosts.contains("file:"); if (showLinkstructure) { diff --git a/htroot/HostBrowser.java b/htroot/HostBrowser.java index fbcf13738..1d3fa4d7b 100644 --- a/htroot/HostBrowser.java +++ b/htroot/HostBrowser.java @@ -514,7 +514,7 @@ public class HostBrowser { prop.put("files_subpathdetectedsize", filecounter - storedDocs.size()); prop.put("files", 1); uri = new DigestURL(path); - prop.put("files_linkgraph", uri.getPath().length() <= 1 && hostsize > 0); + prop.put("files_linkgraph", uri.getPath().length() <= 1 && hostsize > 0 && sb.getConfigBool(SwitchboardConstants.DECORATION_GRAFICS_LINKSTRUCTURE, true)); prop.put("files_linkgraph_host", uri.getHost()); // generate inbound-links table diff --git a/source/net/yacy/search/SwitchboardConstants.java b/source/net/yacy/search/SwitchboardConstants.java index d53e6d92c..fbf162028 100644 --- a/source/net/yacy/search/SwitchboardConstants.java +++ b/source/net/yacy/search/SwitchboardConstants.java @@ -559,5 +559,6 @@ public final class SwitchboardConstants { * decorations */ public static final String DECORATION_AUDIO = "decoration.audio"; + public static final String DECORATION_GRAFICS_LINKSTRUCTURE = "decoration.grafics.linkstructure"; }