From 541b817502053fca87527616cbd1c2400deafa28 Mon Sep 17 00:00:00 2001 From: orbiter Date: Sat, 22 Mar 2008 01:28:37 +0000 Subject: [PATCH] refactoring of switchboard queueing git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@4591 6c8d7289-2bf4-0310-a012-ef5d649a1542 --- htroot/AccessTracker_p.java | 2 +- htroot/Banner.java | 2 +- htroot/BlacklistCleaner_p.java | 2 +- htroot/Blacklist_p.java | 2 +- htroot/Blog.java | 2 +- htroot/BlogComments.java | 4 +- htroot/Bookmarks.java | 2 +- htroot/CacheAdmin_p.java | 2 +- htroot/CacheResource_p.java | 2 +- htroot/ConfigBasic.java | 4 +- htroot/ConfigLanguage_p.java | 2 +- htroot/ConfigNetwork_p.java | 2 +- htroot/ConfigProfile_p.java | 2 +- htroot/ConfigProperties_p.java | 2 +- htroot/ConfigRobotsTxt_p.java | 2 +- htroot/ConfigSkins_p.java | 2 +- htroot/ConfigUpdate_p.java | 2 +- htroot/Config_p.java | 2 +- htroot/Connections_p.java | 2 +- htroot/CookieMonitorIncoming_p.java | 2 +- htroot/CookieMonitorOutgoing_p.java | 2 +- htroot/CookieTest.java | 2 +- htroot/CrawlProfileEditor_p.java | 2 +- htroot/CrawlResults.java | 2 +- htroot/CrawlStartExpert_p.java | 2 +- htroot/CrawlStartSimple_p.java | 2 +- htroot/FeedReader_p.java | 2 +- htroot/IndexCleaner_p.java | 2 +- htroot/IndexControlRWIs_p.java | 2 +- htroot/IndexControlURLs_p.java | 2 +- htroot/IndexCreateIndexingQueue_p.java | 2 +- htroot/IndexCreateLoaderQueue_p.java | 2 +- htroot/IndexCreateWWWGlobalQueue_p.java | 2 +- htroot/IndexCreateWWWLocalQueue_p.java | 2 +- htroot/IndexCreateWWWRemoteQueue_p.java | 2 +- htroot/IndexImport_p.java | 2 +- htroot/IndexShare_p.java | 2 +- htroot/IndexTransfer_p.java | 2 +- htroot/MessageSend_p.java | 2 +- htroot/Messages_p.java | 2 +- htroot/Network.java | 2 +- htroot/NetworkPicture.java | 2 +- htroot/News.java | 2 +- htroot/PeerLoadPicture.java | 2 +- htroot/PerformanceGraph.java | 2 +- htroot/PerformanceMemory_p.java | 2 +- htroot/PerformanceQueues_p.java | 2 +- htroot/PerformanceSearch_p.java | 2 +- htroot/ProxyIndexingMonitor_p.java | 2 +- htroot/QuickCrawlLink_p.java | 2 +- htroot/Ranking_p.java | 2 +- htroot/SearchEventPicture.java | 2 +- htroot/SettingsAck_p.java | 2 +- htroot/Settings_p.java | 2 +- htroot/Statistics.java | 2 +- htroot/Status.java | 2 +- htroot/Steering.java | 2 +- htroot/Supporter.java | 2 +- htroot/Surftips.java | 2 +- htroot/Threaddump_p.java | 2 +- htroot/User.java | 2 +- htroot/User_p.java | 2 +- htroot/ViewFile.java | 2 +- htroot/ViewImage.java | 2 +- htroot/ViewLog_p.java | 2 +- htroot/WatchCrawler_p.java | 2 +- htroot/WatchWebStructure_p.java | 2 +- htroot/WebStructurePicture_p.java | 2 +- htroot/Wiki.java | 2 +- htroot/WikiHelp.java | 2 +- htroot/YaCySearchPluginFF.java | 2 +- htroot/autoconfig.java | 2 +- htroot/imagetest.java | 2 +- htroot/index.java | 2 +- htroot/opensearchdescription.java | 2 +- htroot/osm.java | 2 +- htroot/rct_p.java | 2 +- htroot/robots.java | 2 +- htroot/sharedBlacklist_p.java | 2 +- htroot/ssitestservlet.java | 2 +- htroot/test.java | 2 +- htroot/www/welcome.java | 2 +- htroot/xml/blacklists_p.java | 2 +- htroot/xml/bookmarks/posts/all.java | 2 +- htroot/xml/bookmarks/posts/delete_p.java | 2 +- htroot/xml/bookmarks/posts/get.java | 2 +- htroot/xml/bookmarks/tags/get.java | 2 +- htroot/xml/bookmarks/tags/rename_p.java | 2 +- htroot/xml/bookmarks/xbel/xbel.java | 2 +- htroot/xml/config_p.java | 2 +- htroot/xml/queues_p.java | 2 +- htroot/xml/status_p.java | 2 +- htroot/xml/util/getpageinfo_p.java | 2 +- htroot/xml/version.java | 2 +- htroot/xml/webstructure.java | 2 +- htroot/yacy/crawlReceipt.java | 2 +- htroot/yacy/hello.java | 2 +- htroot/yacy/list.java | 2 +- htroot/yacy/message.java | 4 +- htroot/yacy/profile.java | 2 +- htroot/yacy/query.java | 2 +- htroot/yacy/search.java | 2 +- htroot/yacy/transfer.java | 2 +- htroot/yacy/transferRWI.java | 2 +- htroot/yacy/transferURL.java | 2 +- htroot/yacy/ui/result.java | 2 +- htroot/yacy/ui/ritem.java | 2 +- htroot/yacy/ui/ymarks.java | 2 +- htroot/yacy/urls.java | 2 +- htroot/yacy/user/sidebar_history.java | 2 +- htroot/yacy/user/sidebar_navigation.java | 2 +- htroot/yacy/user/ysearch.java | 2 +- htroot/yacy/user/ysearchitem.java | 2 +- htroot/yacysearch.java | 2 +- htroot/yacysearchitem.java | 2 +- source/de/anomic/data/translator.java | 4 +- .../data/wiki/tokens/DefinitionListToken.java | 2 +- source/de/anomic/http/httpd.java | 4 +- source/de/anomic/http/httpdFileHandler.java | 4 +- .../de/anomic/http/httpdRobotsTxtConfig.java | 2 +- source/de/anomic/http/httpdSwitchboard.java | 80 ------------- .../kelondro/kelondroRowCollection.java | 1 - .../plasma/dbImport/AbstractImporter.java | 2 +- .../de/anomic/plasma/plasmaSwitchboard.java | 112 +++++++++--------- source/de/anomic/plasma/plasmaWordIndex.java | 12 +- .../sch/serverPortForwardingSch.java | 4 +- .../portForwarding/serverPortForwarding.java | 2 +- .../upnp/serverPortForwardingUpnp.java | 2 +- .../anomic/server/serverAbstractSwitch.java | 28 +++-- source/de/anomic/server/serverCore.java | 4 +- .../de/anomic/server/serverPlainSwitch.java | 18 +-- source/de/anomic/server/serverSwitch.java | 7 +- .../yacy/seedUpload/yacySeedUploadFile.java | 2 +- .../yacy/seedUpload/yacySeedUploadFtp.java | 2 +- .../yacy/seedUpload/yacySeedUploadScp.java | 2 +- source/de/anomic/yacy/yacyCore.java | 2 +- source/de/anomic/yacy/yacyNetwork.java | 4 +- source/de/anomic/yacy/yacySeedDB.java | 2 +- source/de/anomic/yacy/yacySeedUploader.java | 2 +- 139 files changed, 234 insertions(+), 306 deletions(-) delete mode 100644 source/de/anomic/http/httpdSwitchboard.java diff --git a/htroot/AccessTracker_p.java b/htroot/AccessTracker_p.java index 97f98e303..7f2f825fb 100644 --- a/htroot/AccessTracker_p.java +++ b/htroot/AccessTracker_p.java @@ -53,7 +53,7 @@ public class AccessTracker_p { return accessClone; } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { plasmaSwitchboard switchboard = (plasmaSwitchboard) sb; // return variable that accumulates replacements diff --git a/htroot/Banner.java b/htroot/Banner.java index 26b4f8758..8b1cc88b9 100644 --- a/htroot/Banner.java +++ b/htroot/Banner.java @@ -60,7 +60,7 @@ import javax.imageio.ImageIO; /** draw a banner with information about the peer */ public class Banner { - public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) throws IOException { + public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) throws IOException { final String IMAGE = "htroot/env/grafics/yacy.gif"; int width = 468; diff --git a/htroot/BlacklistCleaner_p.java b/htroot/BlacklistCleaner_p.java index 76c38d7eb..e583dead6 100644 --- a/htroot/BlacklistCleaner_p.java +++ b/htroot/BlacklistCleaner_p.java @@ -89,7 +89,7 @@ public class BlacklistCleaner_p { defaultURLPattern.class }; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); // initialize the list manager diff --git a/htroot/Blacklist_p.java b/htroot/Blacklist_p.java index dc84d2fb0..b88aeb1e8 100644 --- a/htroot/Blacklist_p.java +++ b/htroot/Blacklist_p.java @@ -74,7 +74,7 @@ public class Blacklist_p { private final static String BLACKLIST = "blackLists_"; private final static String BLACKLIST_SHARED = "BlackLists.Shared"; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // initialize the list manager listManager.switchboard = (plasmaSwitchboard) env; diff --git a/htroot/Blog.java b/htroot/Blog.java index 1f075e460..cd2db62c7 100644 --- a/htroot/Blog.java +++ b/htroot/Blog.java @@ -75,7 +75,7 @@ public class Blog { return SimpleFormatter.format(date); } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard switchboard = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); blogBoard.BlogEntry page = null; diff --git a/htroot/BlogComments.java b/htroot/BlogComments.java index 96b040ab2..e8a8b3bb7 100644 --- a/htroot/BlogComments.java +++ b/htroot/BlogComments.java @@ -76,7 +76,7 @@ public class BlogComments { return SimpleFormatter.format(date); } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); blogBoard.BlogEntry page = null; @@ -338,7 +338,7 @@ public class BlogComments { return prop; } - private static void messageForwardingViaEmail(serverSwitch env, messageBoard.entry msgEntry) { + private static void messageForwardingViaEmail(serverSwitch env, messageBoard.entry msgEntry) { try { if (!Boolean.valueOf(env.getConfig("msgForwardingEnabled","false")).booleanValue()) return; diff --git a/htroot/Bookmarks.java b/htroot/Bookmarks.java index 4928b88b1..cc854bb62 100644 --- a/htroot/Bookmarks.java +++ b/htroot/Bookmarks.java @@ -88,7 +88,7 @@ public class Bookmarks { final static boolean TAGS = false; final static boolean FOLDERS = true; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { int max_count = 10; int start=0; diff --git a/htroot/CacheAdmin_p.java b/htroot/CacheAdmin_p.java index bc7898de9..76be381cb 100644 --- a/htroot/CacheAdmin_p.java +++ b/htroot/CacheAdmin_p.java @@ -95,7 +95,7 @@ public class CacheAdmin_p { } } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard switchboard = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/htroot/CacheResource_p.java b/htroot/CacheResource_p.java index 4148b9ff8..483c6846b 100644 --- a/htroot/CacheResource_p.java +++ b/htroot/CacheResource_p.java @@ -55,7 +55,7 @@ import de.anomic.server.serverSwitch; public class CacheResource_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/ConfigBasic.java b/htroot/ConfigBasic.java index ae7241b21..e60b547e6 100644 --- a/htroot/ConfigBasic.java +++ b/htroot/ConfigBasic.java @@ -73,7 +73,7 @@ public class ConfigBasic { private static final int NEXTSTEP_RECONNECT = 4; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements ConfigBasic config = new ConfigBasic(); @@ -279,7 +279,7 @@ public class ConfigBasic { return new Object[]{upnp,scanForRouter}; } */ - private void reinitPortForwarding(serverObjects post, serverSwitch env) { + private void reinitPortForwarding(serverObjects post, serverSwitch env) { if ((post != null)) { try { boolean reinitPortForwarding = false; diff --git a/htroot/ConfigLanguage_p.java b/htroot/ConfigLanguage_p.java index d20698a5d..a82214914 100644 --- a/htroot/ConfigLanguage_p.java +++ b/htroot/ConfigLanguage_p.java @@ -67,7 +67,7 @@ import de.anomic.yacy.yacyURL; public class ConfigLanguage_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { //listManager.switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); plasmaSwitchboard switchboard = (plasmaSwitchboard) env; diff --git a/htroot/ConfigNetwork_p.java b/htroot/ConfigNetwork_p.java index 4811c02a4..8146ed1c2 100644 --- a/htroot/ConfigNetwork_p.java +++ b/htroot/ConfigNetwork_p.java @@ -35,7 +35,7 @@ import de.anomic.yacy.yacyCore; public class ConfigNetwork_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/ConfigProfile_p.java b/htroot/ConfigProfile_p.java index 5cfdcf7f6..57632ffa7 100644 --- a/htroot/ConfigProfile_p.java +++ b/htroot/ConfigProfile_p.java @@ -63,7 +63,7 @@ import de.anomic.yacy.yacyNewsRecord; public class ConfigProfile_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { //listManager.switchboard = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); final Properties profile = new Properties(); diff --git a/htroot/ConfigProperties_p.java b/htroot/ConfigProperties_p.java index f0816171b..a6165baca 100644 --- a/htroot/ConfigProperties_p.java +++ b/htroot/ConfigProperties_p.java @@ -58,7 +58,7 @@ import de.anomic.server.serverSwitch; public class ConfigProperties_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements final serverObjects prop = new serverObjects(); int count=0; diff --git a/htroot/ConfigRobotsTxt_p.java b/htroot/ConfigRobotsTxt_p.java index d61f8b155..0c527982b 100644 --- a/htroot/ConfigRobotsTxt_p.java +++ b/htroot/ConfigRobotsTxt_p.java @@ -58,7 +58,7 @@ import de.anomic.yacy.yacyCore; public class ConfigRobotsTxt_p { - public static servletProperties respond(httpHeader header, serverObjects post, serverSwitch env) { + public static servletProperties respond(httpHeader header, serverObjects post, serverSwitch env) { final servletProperties prop = new servletProperties(); httpdRobotsTxtConfig rbc = ((plasmaSwitchboard)env).robotstxtConfig; diff --git a/htroot/ConfigSkins_p.java b/htroot/ConfigSkins_p.java index 4791b939a..7a2132701 100644 --- a/htroot/ConfigSkins_p.java +++ b/htroot/ConfigSkins_p.java @@ -90,7 +90,7 @@ public class ConfigSkins_p { return false; } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); plasmaSwitchboard switchboard = (plasmaSwitchboard) env; String skinPath = new File(env.getRootPath(), env.getConfig("skinPath", "DATA/SKINS")).toString(); diff --git a/htroot/ConfigUpdate_p.java b/htroot/ConfigUpdate_p.java index 895e899c4..a557c193c 100644 --- a/htroot/ConfigUpdate_p.java +++ b/htroot/ConfigUpdate_p.java @@ -40,7 +40,7 @@ import de.anomic.yacy.yacyVersion; public class ConfigUpdate_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements final serverObjects prop = new serverObjects(); final plasmaSwitchboard sb = (plasmaSwitchboard) env; diff --git a/htroot/Config_p.java b/htroot/Config_p.java index af3dfe1a6..9e56624e6 100644 --- a/htroot/Config_p.java +++ b/htroot/Config_p.java @@ -58,7 +58,7 @@ import de.anomic.server.serverSwitch; public class Config_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements final serverObjects prop = new serverObjects(); int count=0; diff --git a/htroot/Connections_p.java b/htroot/Connections_p.java index 61d7448a6..528e6fafb 100644 --- a/htroot/Connections_p.java +++ b/htroot/Connections_p.java @@ -69,7 +69,7 @@ import de.anomic.yacy.yacySeed; public final class Connections_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) sb; serverObjects prop = new serverObjects(); diff --git a/htroot/CookieMonitorIncoming_p.java b/htroot/CookieMonitorIncoming_p.java index 1053834dd..5a83751d0 100644 --- a/htroot/CookieMonitorIncoming_p.java +++ b/htroot/CookieMonitorIncoming_p.java @@ -55,7 +55,7 @@ import de.anomic.server.serverSwitch; public class CookieMonitorIncoming_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { plasmaSwitchboard switchboard = (plasmaSwitchboard) sb; // return variable that accumulates replacements diff --git a/htroot/CookieMonitorOutgoing_p.java b/htroot/CookieMonitorOutgoing_p.java index 4c2366e73..25ea9afd5 100644 --- a/htroot/CookieMonitorOutgoing_p.java +++ b/htroot/CookieMonitorOutgoing_p.java @@ -55,7 +55,7 @@ import de.anomic.server.serverSwitch; public class CookieMonitorOutgoing_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { plasmaSwitchboard switchboard = (plasmaSwitchboard) sb; // return variable that accumulates replacements diff --git a/htroot/CookieTest.java b/htroot/CookieTest.java index 3b59bfd81..e621440a4 100644 --- a/htroot/CookieTest.java +++ b/htroot/CookieTest.java @@ -56,7 +56,7 @@ import de.anomic.server.servletProperties; public class CookieTest { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // case if no values are requested diff --git a/htroot/CrawlProfileEditor_p.java b/htroot/CrawlProfileEditor_p.java index b0088f8fd..7b61f6973 100644 --- a/htroot/CrawlProfileEditor_p.java +++ b/htroot/CrawlProfileEditor_p.java @@ -78,7 +78,7 @@ public class CrawlProfileEditor_p { labels.add(new eentry(entry.XPSTOPW, "Parent stop-words", false, eentry.BOOLEAN)); } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final servletProperties prop = new servletProperties(); final plasmaSwitchboard sb = (plasmaSwitchboard)env; diff --git a/htroot/CrawlResults.java b/htroot/CrawlResults.java index d842efd4d..098d1f67d 100644 --- a/htroot/CrawlResults.java +++ b/htroot/CrawlResults.java @@ -42,7 +42,7 @@ import de.anomic.yacy.yacyURL; public class CrawlResults { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/htroot/CrawlStartExpert_p.java b/htroot/CrawlStartExpert_p.java index bc2e394d0..52a8916f9 100644 --- a/htroot/CrawlStartExpert_p.java +++ b/htroot/CrawlStartExpert_p.java @@ -31,7 +31,7 @@ import de.anomic.server.serverSwitch; public class CrawlStartExpert_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); diff --git a/htroot/CrawlStartSimple_p.java b/htroot/CrawlStartSimple_p.java index 38786fec2..f70b38d9c 100644 --- a/htroot/CrawlStartSimple_p.java +++ b/htroot/CrawlStartSimple_p.java @@ -38,7 +38,7 @@ import de.anomic.yacy.yacyURL; public class CrawlStartSimple_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); diff --git a/htroot/FeedReader_p.java b/htroot/FeedReader_p.java index 6fe271302..bf8af786e 100644 --- a/htroot/FeedReader_p.java +++ b/htroot/FeedReader_p.java @@ -35,7 +35,7 @@ import de.anomic.yacy.yacyURL; public class FeedReader_p { - public static servletProperties respond(httpHeader header, serverObjects post, serverSwitch env) { + public static servletProperties respond(httpHeader header, serverObjects post, serverSwitch env) { servletProperties prop = new servletProperties(); prop.put("page", "0"); diff --git a/htroot/IndexCleaner_p.java b/htroot/IndexCleaner_p.java index a5dc388a5..bee194f54 100755 --- a/htroot/IndexCleaner_p.java +++ b/htroot/IndexCleaner_p.java @@ -54,7 +54,7 @@ public class IndexCleaner_p { private static plasmaCrawlLURL.Cleaner urldbCleanerThread; private static plasmaWordIndex.Cleaner indexCleanerThread; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); plasmaSwitchboard sb = (plasmaSwitchboard) env; prop.put("title", "DbCleanup_p"); diff --git a/htroot/IndexControlRWIs_p.java b/htroot/IndexControlRWIs_p.java index 9f811cd93..4928a14f4 100644 --- a/htroot/IndexControlRWIs_p.java +++ b/htroot/IndexControlRWIs_p.java @@ -56,7 +56,7 @@ import de.anomic.yacy.yacyURL; public class IndexControlRWIs_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/IndexControlURLs_p.java b/htroot/IndexControlURLs_p.java index f7d35ce9f..555fa7592 100644 --- a/htroot/IndexControlURLs_p.java +++ b/htroot/IndexControlURLs_p.java @@ -43,7 +43,7 @@ import de.anomic.yacy.yacyURL; public class IndexControlURLs_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard sb = (plasmaSwitchboard) env; diff --git a/htroot/IndexCreateIndexingQueue_p.java b/htroot/IndexCreateIndexingQueue_p.java index e3ce0ae29..c7a5099bc 100644 --- a/htroot/IndexCreateIndexingQueue_p.java +++ b/htroot/IndexCreateIndexingQueue_p.java @@ -60,7 +60,7 @@ import de.anomic.yacy.yacyURL; public class IndexCreateIndexingQueue_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/IndexCreateLoaderQueue_p.java b/htroot/IndexCreateLoaderQueue_p.java index ba641353a..c72707229 100644 --- a/htroot/IndexCreateLoaderQueue_p.java +++ b/htroot/IndexCreateLoaderQueue_p.java @@ -53,7 +53,7 @@ import de.anomic.yacy.yacySeed; public class IndexCreateLoaderQueue_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/IndexCreateWWWGlobalQueue_p.java b/htroot/IndexCreateWWWGlobalQueue_p.java index a184b89a1..dbb7bdba2 100644 --- a/htroot/IndexCreateWWWGlobalQueue_p.java +++ b/htroot/IndexCreateWWWGlobalQueue_p.java @@ -65,7 +65,7 @@ public class IndexCreateWWWGlobalQueue_p { return dayFormatter.format(date); } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/IndexCreateWWWLocalQueue_p.java b/htroot/IndexCreateWWWLocalQueue_p.java index ea1745c47..1e25e2b7f 100644 --- a/htroot/IndexCreateWWWLocalQueue_p.java +++ b/htroot/IndexCreateWWWLocalQueue_p.java @@ -77,7 +77,7 @@ public class IndexCreateWWWLocalQueue_p { private static final int INITIATOR = 5; private static final int MODIFIED = 6; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/IndexCreateWWWRemoteQueue_p.java b/htroot/IndexCreateWWWRemoteQueue_p.java index a874e0474..e7468c4de 100644 --- a/htroot/IndexCreateWWWRemoteQueue_p.java +++ b/htroot/IndexCreateWWWRemoteQueue_p.java @@ -66,7 +66,7 @@ public class IndexCreateWWWRemoteQueue_p { return dayFormatter.format(date); } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final servletProperties prop = new servletProperties(); final plasmaSwitchboard sb = (plasmaSwitchboard)env; diff --git a/htroot/IndexImport_p.java b/htroot/IndexImport_p.java index 490f70156..d5d56c7ef 100644 --- a/htroot/IndexImport_p.java +++ b/htroot/IndexImport_p.java @@ -61,7 +61,7 @@ import de.anomic.server.serverSwitch; public final class IndexImport_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/IndexShare_p.java b/htroot/IndexShare_p.java index 5ac16f920..e9f127b52 100644 --- a/htroot/IndexShare_p.java +++ b/htroot/IndexShare_p.java @@ -55,7 +55,7 @@ import de.anomic.server.serverSwitch; public class IndexShare_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/IndexTransfer_p.java b/htroot/IndexTransfer_p.java index c30df8d15..e6f99372a 100644 --- a/htroot/IndexTransfer_p.java +++ b/htroot/IndexTransfer_p.java @@ -63,7 +63,7 @@ import de.anomic.yacy.yacySeed; public final class IndexTransfer_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/MessageSend_p.java b/htroot/MessageSend_p.java index af9e144c3..d9c276df1 100644 --- a/htroot/MessageSend_p.java +++ b/htroot/MessageSend_p.java @@ -64,7 +64,7 @@ public class MessageSend_p { } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); if ((post == null) || (post.get("hash","").length() == 0)) { diff --git a/htroot/Messages_p.java b/htroot/Messages_p.java index 1e048245a..9f6d34ddb 100644 --- a/htroot/Messages_p.java +++ b/htroot/Messages_p.java @@ -70,7 +70,7 @@ public class Messages_p { return SimpleFormatter.format(date); } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/Network.java b/htroot/Network.java index dfca48987..d339ed4e5 100644 --- a/htroot/Network.java +++ b/htroot/Network.java @@ -72,7 +72,7 @@ public class Network { private static final String STR_TABLE_LIST = "table_list_"; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch switchboard) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch switchboard) { plasmaSwitchboard sb = (plasmaSwitchboard) switchboard; final long start = System.currentTimeMillis(); diff --git a/htroot/NetworkPicture.java b/htroot/NetworkPicture.java index d45bedcbc..e88cdd3b4 100644 --- a/htroot/NetworkPicture.java +++ b/htroot/NetworkPicture.java @@ -52,7 +52,7 @@ import de.anomic.ymage.ymageMatrix; /** draw a picture of the yacy network */ public class NetworkPicture { - public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { + public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { int width = 768; int height = 576; diff --git a/htroot/News.java b/htroot/News.java index 436e5a73c..137d4b18e 100644 --- a/htroot/News.java +++ b/htroot/News.java @@ -60,7 +60,7 @@ import de.anomic.yacy.yacySeed; public class News { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); boolean overview = (post == null) || (post.get("page", "0").equals("0")); diff --git a/htroot/PeerLoadPicture.java b/htroot/PeerLoadPicture.java index e144a2566..ab39d9bef 100644 --- a/htroot/PeerLoadPicture.java +++ b/htroot/PeerLoadPicture.java @@ -13,7 +13,7 @@ import de.anomic.server.serverThread; public class PeerLoadPicture { - public static Image respond(httpHeader header, serverObjects post, serverSwitch env) { + public static Image respond(httpHeader header, serverObjects post, serverSwitch env) { int width = 800; int height = 600; diff --git a/htroot/PerformanceGraph.java b/htroot/PerformanceGraph.java index 9ccd1c017..45ad9dc81 100644 --- a/htroot/PerformanceGraph.java +++ b/htroot/PerformanceGraph.java @@ -32,7 +32,7 @@ import de.anomic.ymage.ymageMatrix; public class PerformanceGraph { - public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { + public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { //plasmaSwitchboard sb = (plasmaSwitchboard) env; if (post == null) post = new serverObjects(); diff --git a/htroot/PerformanceMemory_p.java b/htroot/PerformanceMemory_p.java index 4e8e83a59..5b1287991 100644 --- a/htroot/PerformanceMemory_p.java +++ b/htroot/PerformanceMemory_p.java @@ -66,7 +66,7 @@ public class PerformanceMemory_p { private static final long MB = 1024 * KB; private static Map defaultSettings = null; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); if (defaultSettings == null) { diff --git a/htroot/PerformanceQueues_p.java b/htroot/PerformanceQueues_p.java index ed3101c11..8b59b8b67 100644 --- a/htroot/PerformanceQueues_p.java +++ b/htroot/PerformanceQueues_p.java @@ -58,7 +58,7 @@ import de.anomic.tools.yFormatter; public class PerformanceQueues_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) sb; serverObjects prop = new serverObjects(); diff --git a/htroot/PerformanceSearch_p.java b/htroot/PerformanceSearch_p.java index 54b921f19..64981af85 100644 --- a/htroot/PerformanceSearch_p.java +++ b/htroot/PerformanceSearch_p.java @@ -35,7 +35,7 @@ import de.anomic.server.serverSwitch; public class PerformanceSearch_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); diff --git a/htroot/ProxyIndexingMonitor_p.java b/htroot/ProxyIndexingMonitor_p.java index bf5bdb689..123624367 100644 --- a/htroot/ProxyIndexingMonitor_p.java +++ b/htroot/ProxyIndexingMonitor_p.java @@ -62,7 +62,7 @@ public class ProxyIndexingMonitor_p { // if (date == null) return ""; else return dayFormatter.format(date); // } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/QuickCrawlLink_p.java b/htroot/QuickCrawlLink_p.java index 537178685..c21d962fb 100644 --- a/htroot/QuickCrawlLink_p.java +++ b/htroot/QuickCrawlLink_p.java @@ -71,7 +71,7 @@ public class QuickCrawlLink_p { * @param env the serverSwitch object holding all runtime-data * @return the rewrite-properties for the template */ - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); plasmaSwitchboard switchboard = (plasmaSwitchboard)env; diff --git a/htroot/Ranking_p.java b/htroot/Ranking_p.java index 4a5560b68..f9fe9a988 100644 --- a/htroot/Ranking_p.java +++ b/htroot/Ranking_p.java @@ -128,7 +128,7 @@ public class Ranking_p { } } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; // clean up all search events diff --git a/htroot/SearchEventPicture.java b/htroot/SearchEventPicture.java index 068a9305d..d09c08298 100644 --- a/htroot/SearchEventPicture.java +++ b/htroot/SearchEventPicture.java @@ -55,7 +55,7 @@ import de.anomic.ymage.ymageMatrix; public class SearchEventPicture { - public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { + public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { String eventID = (String) header.get("event", plasmaSearchEvent.lastEventID); if (eventID == null) return null; diff --git a/htroot/SettingsAck_p.java b/htroot/SettingsAck_p.java index cd5a64084..ef34338ca 100644 --- a/htroot/SettingsAck_p.java +++ b/htroot/SettingsAck_p.java @@ -79,7 +79,7 @@ public class SettingsAck_p { private static boolean nothingChanged; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); diff --git a/htroot/Settings_p.java b/htroot/Settings_p.java index 086d51283..10b9edb04 100644 --- a/htroot/Settings_p.java +++ b/htroot/Settings_p.java @@ -60,7 +60,7 @@ import de.anomic.yacy.yacySeedUploader; public final class Settings_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); diff --git a/htroot/Statistics.java b/htroot/Statistics.java index eaf3aaf59..8438b18f9 100644 --- a/htroot/Statistics.java +++ b/htroot/Statistics.java @@ -55,7 +55,7 @@ import de.anomic.yacy.yacyURL; public class Statistics { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch sb) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) sb; serverObjects prop = new serverObjects(); diff --git a/htroot/Status.java b/htroot/Status.java index b161c6d86..fa98918c5 100644 --- a/htroot/Status.java +++ b/htroot/Status.java @@ -70,7 +70,7 @@ public class Status { private static final String SEEDSERVER = "seedServer"; private static final String PEERSTATUS = "peerStatus"; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements final serverObjects prop = new serverObjects(); final plasmaSwitchboard sb = (plasmaSwitchboard) env; diff --git a/htroot/Steering.java b/htroot/Steering.java index b4a15b9c7..c67cc08d5 100644 --- a/htroot/Steering.java +++ b/htroot/Steering.java @@ -56,7 +56,7 @@ import de.anomic.yacy.yacyVersion; public class Steering { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch ss) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch ss) { if (post == null || ss == null) { return new serverObjects(); } final plasmaSwitchboard sb = (plasmaSwitchboard) ss; diff --git a/htroot/Supporter.java b/htroot/Supporter.java index 96b7a2c64..bce3c8577 100644 --- a/htroot/Supporter.java +++ b/htroot/Supporter.java @@ -51,7 +51,7 @@ import de.anomic.yacy.yacyURL; public class Supporter { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/htroot/Surftips.java b/htroot/Surftips.java index 13ff746dc..65bbb8887 100644 --- a/htroot/Surftips.java +++ b/htroot/Surftips.java @@ -51,7 +51,7 @@ import de.anomic.yacy.yacyURL; public class Surftips { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/htroot/Threaddump_p.java b/htroot/Threaddump_p.java index a3e54b3b9..2b964f7e3 100644 --- a/htroot/Threaddump_p.java +++ b/htroot/Threaddump_p.java @@ -68,7 +68,7 @@ public class Threaddump_p { private static serverObjects prop; private static plasmaSwitchboard sb; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { prop = new serverObjects(); sb = (plasmaSwitchboard) env; diff --git a/htroot/User.java b/htroot/User.java index 1e0f92ede..a2ec2cb7e 100644 --- a/htroot/User.java +++ b/htroot/User.java @@ -60,7 +60,7 @@ import de.anomic.server.servletProperties; public class User{ - public static servletProperties respond(httpHeader header, serverObjects post, serverSwitch env) { + public static servletProperties respond(httpHeader header, serverObjects post, serverSwitch env) { servletProperties prop = new servletProperties(); plasmaSwitchboard sb = plasmaSwitchboard.getSwitchboard(); userDB.Entry entry=null; diff --git a/htroot/User_p.java b/htroot/User_p.java index d825bccd0..f9ca82307 100644 --- a/htroot/User_p.java +++ b/htroot/User_p.java @@ -59,7 +59,7 @@ import de.anomic.server.serverSwitch; public class User_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); plasmaSwitchboard sb = plasmaSwitchboard.getSwitchboard(); userDB.Entry entry=null; diff --git a/htroot/ViewFile.java b/htroot/ViewFile.java index ef3a55f5c..04a4df611 100644 --- a/htroot/ViewFile.java +++ b/htroot/ViewFile.java @@ -82,7 +82,7 @@ public class ViewFile { private static final String HIGHLIGHT_CSS = "searchHighlight"; private static final int MAX_HIGHLIGHTS = 6; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); plasmaSwitchboard sb = (plasmaSwitchboard)env; diff --git a/htroot/ViewImage.java b/htroot/ViewImage.java index 90878495f..53b4c3291 100644 --- a/htroot/ViewImage.java +++ b/htroot/ViewImage.java @@ -62,7 +62,7 @@ public class ViewImage { private static HashMap iconcache = new HashMap(); private static String defaulticon = "htroot/env/grafics/dfltfvcn.ico"; - public static Image respond(httpHeader header, serverObjects post, serverSwitch env) { + public static Image respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard sb = (plasmaSwitchboard)env; diff --git a/htroot/ViewLog_p.java b/htroot/ViewLog_p.java index 5d32ecfd0..4825c6808 100644 --- a/htroot/ViewLog_p.java +++ b/htroot/ViewLog_p.java @@ -60,7 +60,7 @@ import de.anomic.server.logging.LogalizerHandler; public class ViewLog_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); String[] log = new String[0]; boolean reversed = false; diff --git a/htroot/WatchCrawler_p.java b/htroot/WatchCrawler_p.java index adbf2fa22..563429909 100644 --- a/htroot/WatchCrawler_p.java +++ b/htroot/WatchCrawler_p.java @@ -59,7 +59,7 @@ public class WatchCrawler_p { // this servlet does NOT create the WatchCrawler page content! // this servlet starts a web crawl. The interface for entering the web crawl parameters is in IndexCreate_p.html - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/WatchWebStructure_p.java b/htroot/WatchWebStructure_p.java index 693e126d1..5dcb8488e 100644 --- a/htroot/WatchWebStructure_p.java +++ b/htroot/WatchWebStructure_p.java @@ -9,7 +9,7 @@ import de.anomic.server.serverSwitch; public class WatchWebStructure_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/WebStructurePicture_p.java b/htroot/WebStructurePicture_p.java index 36a55a243..9a5f03775 100644 --- a/htroot/WebStructurePicture_p.java +++ b/htroot/WebStructurePicture_p.java @@ -45,7 +45,7 @@ public class WebStructurePicture_p { private static final double maxlongd = Long.MAX_VALUE; - public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { + public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard sb = (plasmaSwitchboard) env; int width = 768; diff --git a/htroot/Wiki.java b/htroot/Wiki.java index 26f4e33fc..f78770229 100644 --- a/htroot/Wiki.java +++ b/htroot/Wiki.java @@ -74,7 +74,7 @@ public class Wiki { } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) throws IOException { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) throws IOException { plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); if (post == null) { diff --git a/htroot/WikiHelp.java b/htroot/WikiHelp.java index 12a3d7313..1951aa9b6 100644 --- a/htroot/WikiHelp.java +++ b/htroot/WikiHelp.java @@ -52,7 +52,7 @@ import de.anomic.server.serverSwitch; public class WikiHelp { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { //final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); return prop; diff --git a/htroot/YaCySearchPluginFF.java b/htroot/YaCySearchPluginFF.java index 4564d132e..fcbe4caf0 100644 --- a/htroot/YaCySearchPluginFF.java +++ b/htroot/YaCySearchPluginFF.java @@ -56,7 +56,7 @@ public class YaCySearchPluginFF { * @param env the serverSwitch object holding all runtime-data * @return the rewrite-properties for the template */ - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); diff --git a/htroot/autoconfig.java b/htroot/autoconfig.java index a5a07eb40..cca46f477 100644 --- a/htroot/autoconfig.java +++ b/htroot/autoconfig.java @@ -57,7 +57,7 @@ public class autoconfig { * @param env the serverSwitch object holding all runtime-data * @return the rewrite-properties for the template */ - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); diff --git a/htroot/imagetest.java b/htroot/imagetest.java index b6151e5ff..2b8e02a3f 100644 --- a/htroot/imagetest.java +++ b/htroot/imagetest.java @@ -51,7 +51,7 @@ import de.anomic.ymage.ymageToolPrint; public class imagetest { - public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { + public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { /* BufferedImage bi = new BufferedImage(640, 400, BufferedImage.TYPE_INT_RGB); Graphics2D g = bi.createGraphics(); diff --git a/htroot/index.java b/htroot/index.java index f6c323e6b..4514204e3 100644 --- a/htroot/index.java +++ b/htroot/index.java @@ -38,7 +38,7 @@ import de.anomic.yacy.yacyCore; public class index { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/htroot/opensearchdescription.java b/htroot/opensearchdescription.java index 269a4d817..02f0b9c97 100644 --- a/htroot/opensearchdescription.java +++ b/htroot/opensearchdescription.java @@ -32,7 +32,7 @@ import de.anomic.yacy.yacyCore; public class opensearchdescription { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // generate message content for open search description String promoteSearchPageGreeting = env.getConfig("promoteSearchPageGreeting", ""); diff --git a/htroot/osm.java b/htroot/osm.java index 8e8b3b60a..4d5e57ef3 100644 --- a/htroot/osm.java +++ b/htroot/osm.java @@ -8,7 +8,7 @@ import de.anomic.ymage.ymageOSM; public class osm { - public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { + public static ymageMatrix respond(httpHeader header, serverObjects post, serverSwitch env) { int zoom = 10; double lat = 47.968056d; diff --git a/htroot/rct_p.java b/htroot/rct_p.java index 0191d1bca..e1f73bf70 100644 --- a/htroot/rct_p.java +++ b/htroot/rct_p.java @@ -43,7 +43,7 @@ import de.anomic.yacy.yacyURL; public class rct_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/robots.java b/htroot/robots.java index 69fbea406..ed7154765 100644 --- a/htroot/robots.java +++ b/htroot/robots.java @@ -12,7 +12,7 @@ import de.anomic.server.servletProperties; public class robots { - public static servletProperties respond(httpHeader header, serverObjects post, serverSwitch env) { + public static servletProperties respond(httpHeader header, serverObjects post, serverSwitch env) { final servletProperties prop = new servletProperties(); final httpdRobotsTxtConfig rbc = ((plasmaSwitchboard)env).robotstxtConfig; diff --git a/htroot/sharedBlacklist_p.java b/htroot/sharedBlacklist_p.java index 6418e841d..3b7b20d88 100644 --- a/htroot/sharedBlacklist_p.java +++ b/htroot/sharedBlacklist_p.java @@ -76,7 +76,7 @@ public class sharedBlacklist_p { public static final int STATUS_URL_PROBLEM = 4; public static final int STATUS_WRONG_INVOCATION = 5; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); plasmaSwitchboard switchboard = (plasmaSwitchboard) env; diff --git a/htroot/ssitestservlet.java b/htroot/ssitestservlet.java index 54e70802f..56a0cc869 100644 --- a/htroot/ssitestservlet.java +++ b/htroot/ssitestservlet.java @@ -31,7 +31,7 @@ import de.anomic.server.serverSwitch; public class ssitestservlet { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { //plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/test.java b/htroot/test.java index e1c79e552..06d189554 100644 --- a/htroot/test.java +++ b/htroot/test.java @@ -6,7 +6,7 @@ public class test { // http://localhost:8080/test.xml?count=10 - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); int count = Math.min(1000, (post == null) ? 0 : post.getInt("count", 0)); diff --git a/htroot/www/welcome.java b/htroot/www/welcome.java index 92d0aa5a1..bd2337025 100644 --- a/htroot/www/welcome.java +++ b/htroot/www/welcome.java @@ -61,7 +61,7 @@ import de.anomic.yacy.yacySeed; public class welcome { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements final serverObjects prop = new serverObjects(); diff --git a/htroot/xml/blacklists_p.java b/htroot/xml/blacklists_p.java index ddc570b41..5cf34acbd 100644 --- a/htroot/xml/blacklists_p.java +++ b/htroot/xml/blacklists_p.java @@ -31,7 +31,7 @@ import de.anomic.server.serverSwitch; public class blacklists_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); listManager.listsPath = new File(listManager.switchboard.getRootPath(),listManager.switchboard.getConfig("listManager.listsPath", "DATA/LISTS")); diff --git a/htroot/xml/bookmarks/posts/all.java b/htroot/xml/bookmarks/posts/all.java index 6396ac2cb..6fc975e8f 100644 --- a/htroot/xml/bookmarks/posts/all.java +++ b/htroot/xml/bookmarks/posts/all.java @@ -57,7 +57,7 @@ import de.anomic.server.serverObjects; import de.anomic.server.serverSwitch; public class all { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; boolean isAdmin=switchboard.verifyAuthentication(header, true); diff --git a/htroot/xml/bookmarks/posts/delete_p.java b/htroot/xml/bookmarks/posts/delete_p.java index 25969eb5b..1ca020171 100644 --- a/htroot/xml/bookmarks/posts/delete_p.java +++ b/htroot/xml/bookmarks/posts/delete_p.java @@ -51,7 +51,7 @@ import de.anomic.server.serverSwitch; import de.anomic.yacy.yacyURL; public class delete_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/xml/bookmarks/posts/get.java b/htroot/xml/bookmarks/posts/get.java index ceb5d6123..fd764f983 100644 --- a/htroot/xml/bookmarks/posts/get.java +++ b/htroot/xml/bookmarks/posts/get.java @@ -33,7 +33,7 @@ import de.anomic.server.serverObjects; import de.anomic.server.serverSwitch; public class get { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; boolean isAdmin=switchboard.verifyAuthentication(header, true); diff --git a/htroot/xml/bookmarks/tags/get.java b/htroot/xml/bookmarks/tags/get.java index a5f44ee8a..dbd80bad1 100644 --- a/htroot/xml/bookmarks/tags/get.java +++ b/htroot/xml/bookmarks/tags/get.java @@ -56,7 +56,7 @@ import de.anomic.server.serverObjects; import de.anomic.server.serverSwitch; public class get { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; boolean isAdmin=switchboard.verifyAuthentication(header, true); diff --git a/htroot/xml/bookmarks/tags/rename_p.java b/htroot/xml/bookmarks/tags/rename_p.java index acb83b8d9..287ffd77b 100644 --- a/htroot/xml/bookmarks/tags/rename_p.java +++ b/htroot/xml/bookmarks/tags/rename_p.java @@ -52,7 +52,7 @@ import de.anomic.server.serverObjects; import de.anomic.server.serverSwitch; public class rename_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/xml/bookmarks/xbel/xbel.java b/htroot/xml/bookmarks/xbel/xbel.java index 3ce97e581..4b692b209 100644 --- a/htroot/xml/bookmarks/xbel/xbel.java +++ b/htroot/xml/bookmarks/xbel/xbel.java @@ -14,7 +14,7 @@ public class xbel { private static plasmaSwitchboard switchboard; private static boolean isAdmin; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { int count = 0;; diff --git a/htroot/xml/config_p.java b/htroot/xml/config_p.java index 8a13659ed..2bd64f747 100644 --- a/htroot/xml/config_p.java +++ b/htroot/xml/config_p.java @@ -34,7 +34,7 @@ import de.anomic.server.serverSwitch; public class config_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements //plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/xml/queues_p.java b/htroot/xml/queues_p.java index 912f83c2b..2894f1499 100644 --- a/htroot/xml/queues_p.java +++ b/htroot/xml/queues_p.java @@ -74,7 +74,7 @@ public class queues_p { return dayFormatter.format(date); } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard sb = (plasmaSwitchboard) env; //wikiCode wikiTransformer = new wikiCode(switchboard); diff --git a/htroot/xml/status_p.java b/htroot/xml/status_p.java index dcd90e471..d09337353 100644 --- a/htroot/xml/status_p.java +++ b/htroot/xml/status_p.java @@ -52,7 +52,7 @@ import de.anomic.yacy.yacyCore; public class status_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/xml/util/getpageinfo_p.java b/htroot/xml/util/getpageinfo_p.java index 4e13a42aa..7e6a84b9b 100644 --- a/htroot/xml/util/getpageinfo_p.java +++ b/htroot/xml/util/getpageinfo_p.java @@ -62,7 +62,7 @@ import de.anomic.server.serverSwitch; import de.anomic.yacy.yacyURL; public class getpageinfo_p { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); prop.put("sitemap", ""); prop.put("title", ""); diff --git a/htroot/xml/version.java b/htroot/xml/version.java index e0accc479..20c275ae1 100644 --- a/htroot/xml/version.java +++ b/htroot/xml/version.java @@ -29,7 +29,7 @@ import de.anomic.server.serverSwitch; public class version { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); diff --git a/htroot/xml/webstructure.java b/htroot/xml/webstructure.java index 6b67e1672..6d1f08994 100644 --- a/htroot/xml/webstructure.java +++ b/htroot/xml/webstructure.java @@ -38,7 +38,7 @@ import de.anomic.server.serverSwitch; public class webstructure { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { serverObjects prop = new serverObjects(); plasmaSwitchboard sb = (plasmaSwitchboard) env; Iterator i = sb.webStructure.structureEntryIterator(); diff --git a/htroot/yacy/crawlReceipt.java b/htroot/yacy/crawlReceipt.java index eaf825ce0..481d5fbf0 100644 --- a/htroot/yacy/crawlReceipt.java +++ b/htroot/yacy/crawlReceipt.java @@ -67,7 +67,7 @@ public final class crawlReceipt { * this is used to respond on a remote crawling request */ - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements plasmaSwitchboard switchboard = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); diff --git a/htroot/yacy/hello.java b/htroot/yacy/hello.java index a25bb8f9c..66733a88e 100644 --- a/htroot/yacy/hello.java +++ b/htroot/yacy/hello.java @@ -64,7 +64,7 @@ import de.anomic.yacy.yacyVersion; public final class hello { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) throws InterruptedException { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) throws InterruptedException { plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); prop.put("message", "none"); diff --git a/htroot/yacy/list.java b/htroot/yacy/list.java index 94092dfdb..1d071b23c 100644 --- a/htroot/yacy/list.java +++ b/htroot/yacy/list.java @@ -41,7 +41,7 @@ import de.anomic.yacy.yacySeed; public final class list { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { if (post == null || env == null) throw new NullPointerException("post: " + post + ", sb: " + env); plasmaSwitchboard sb = (plasmaSwitchboard) env; diff --git a/htroot/yacy/message.java b/htroot/yacy/message.java index 197547c60..e7a9297fc 100644 --- a/htroot/yacy/message.java +++ b/htroot/yacy/message.java @@ -72,7 +72,7 @@ public final class message { return SimpleFormatter.format(date); } - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { if (post == null || env == null) { return null; } // return variable that accumulates replacements @@ -181,7 +181,7 @@ public final class message { #[message]# */ - private static void messageForwardingViaEmail(serverSwitch env, messageBoard.entry msgEntry) { + private static void messageForwardingViaEmail(serverSwitch env, messageBoard.entry msgEntry) { try { if (!Boolean.valueOf(env.getConfig("msgForwardingEnabled","false")).booleanValue()) return; diff --git a/htroot/yacy/profile.java b/htroot/yacy/profile.java index dd10cdfd0..d84cf66c9 100644 --- a/htroot/yacy/profile.java +++ b/htroot/yacy/profile.java @@ -62,7 +62,7 @@ import de.anomic.yacy.yacyNetwork; public final class profile { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements serverObjects prop = new serverObjects(); plasmaSwitchboard sb = (plasmaSwitchboard) env; diff --git a/htroot/yacy/query.java b/htroot/yacy/query.java index b25d9e249..c8fbf45e0 100644 --- a/htroot/yacy/query.java +++ b/htroot/yacy/query.java @@ -56,7 +56,7 @@ import de.anomic.yacy.yacyNetwork; public final class query { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch ss) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch ss) { if (post == null || ss == null) { return null; } // return variable that accumulates replacements diff --git a/htroot/yacy/search.java b/htroot/yacy/search.java index a373b33e0..4b382e213 100644 --- a/htroot/yacy/search.java +++ b/htroot/yacy/search.java @@ -58,7 +58,7 @@ import de.anomic.yacy.yacyURL; public final class search { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { // return variable that accumulates replacements final plasmaSwitchboard sb = (plasmaSwitchboard) env; sb.remoteSearchLastAccess = System.currentTimeMillis(); diff --git a/htroot/yacy/transfer.java b/htroot/yacy/transfer.java index c66b249c9..23f79df15 100644 --- a/htroot/yacy/transfer.java +++ b/htroot/yacy/transfer.java @@ -60,7 +60,7 @@ import de.anomic.yacy.yacySeed; public final class transfer { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard sb = (plasmaSwitchboard) env; serverObjects prop = new serverObjects(); if ((post == null) || (env == null)) return prop; diff --git a/htroot/yacy/transferRWI.java b/htroot/yacy/transferRWI.java index 03c16fbf0..384878fbe 100644 --- a/htroot/yacy/transferRWI.java +++ b/htroot/yacy/transferRWI.java @@ -65,7 +65,7 @@ import de.anomic.yacy.yacySeed; public final class transferRWI { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) throws InterruptedException { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) throws InterruptedException { // return variable that accumulates replacements final plasmaSwitchboard sb = (plasmaSwitchboard) env; diff --git a/htroot/yacy/transferURL.java b/htroot/yacy/transferURL.java index 6708b9e8e..da35f8c4c 100644 --- a/htroot/yacy/transferURL.java +++ b/htroot/yacy/transferURL.java @@ -63,7 +63,7 @@ import de.anomic.yacy.yacySeed; public final class transferURL { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) throws InterruptedException { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) throws InterruptedException { long start = System.currentTimeMillis(); long freshdate = 0; try {freshdate = serverDate.parseShortDay("20061101").getTime();} catch (ParseException e1) {} diff --git a/htroot/yacy/ui/result.java b/htroot/yacy/ui/result.java index 241b5ba04..9b2dad521 100644 --- a/htroot/yacy/ui/result.java +++ b/htroot/yacy/ui/result.java @@ -44,7 +44,7 @@ import de.anomic.yacy.yacyURL; public class result { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; sb.localSearchLastAccess = System.currentTimeMillis(); diff --git a/htroot/yacy/ui/ritem.java b/htroot/yacy/ui/ritem.java index 4c4c3f1e6..b23fcd52a 100644 --- a/htroot/yacy/ui/ritem.java +++ b/htroot/yacy/ui/ritem.java @@ -49,7 +49,7 @@ public class ritem { private static final int namelength = 60; private static final int urllength = 120; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/htroot/yacy/ui/ymarks.java b/htroot/yacy/ui/ymarks.java index caca09544..148472f70 100644 --- a/htroot/yacy/ui/ymarks.java +++ b/htroot/yacy/ui/ymarks.java @@ -88,7 +88,7 @@ public class ymarks { final static boolean TAGS = false; final static boolean FOLDERS = true; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { int max_count = 1000; int start=0; diff --git a/htroot/yacy/urls.java b/htroot/yacy/urls.java index c114d6a75..3f1031635 100644 --- a/htroot/yacy/urls.java +++ b/htroot/yacy/urls.java @@ -40,7 +40,7 @@ import de.anomic.yacy.yacyURL; public class urls { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { plasmaSwitchboard sb = (plasmaSwitchboard) env; // insert default values diff --git a/htroot/yacy/user/sidebar_history.java b/htroot/yacy/user/sidebar_history.java index 834f0da73..325dd09da 100644 --- a/htroot/yacy/user/sidebar_history.java +++ b/htroot/yacy/user/sidebar_history.java @@ -35,7 +35,7 @@ import de.anomic.server.serverSwitch; public class sidebar_history { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/htroot/yacy/user/sidebar_navigation.java b/htroot/yacy/user/sidebar_navigation.java index a5539452c..8a9da0a5e 100644 --- a/htroot/yacy/user/sidebar_navigation.java +++ b/htroot/yacy/user/sidebar_navigation.java @@ -42,7 +42,7 @@ public class sidebar_navigation { private static final int MAX_TOPWORDS = 24; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final serverObjects prop = new serverObjects(); String eventID = post.get("eventID", ""); diff --git a/htroot/yacy/user/ysearch.java b/htroot/yacy/user/ysearch.java index 10b22f8ba..3f704857d 100644 --- a/htroot/yacy/user/ysearch.java +++ b/htroot/yacy/user/ysearch.java @@ -44,7 +44,7 @@ import de.anomic.yacy.yacyURL; public class ysearch { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; sb.localSearchLastAccess = System.currentTimeMillis(); diff --git a/htroot/yacy/user/ysearchitem.java b/htroot/yacy/user/ysearchitem.java index bd69106a7..ca8111d67 100644 --- a/htroot/yacy/user/ysearchitem.java +++ b/htroot/yacy/user/ysearchitem.java @@ -49,7 +49,7 @@ public class ysearchitem { private static final int namelength = 60; private static final int urllength = 120; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/htroot/yacysearch.java b/htroot/yacysearch.java index da40f1b36..e2cde895d 100644 --- a/htroot/yacysearch.java +++ b/htroot/yacysearch.java @@ -72,7 +72,7 @@ import de.anomic.yacy.yacyURL; public class yacysearch { - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; sb.localSearchLastAccess = System.currentTimeMillis(); diff --git a/htroot/yacysearchitem.java b/htroot/yacysearchitem.java index 9af955ba5..be5b1a657 100644 --- a/htroot/yacysearchitem.java +++ b/htroot/yacysearchitem.java @@ -58,7 +58,7 @@ public class yacysearchitem { private static final int urllength = 120; private static final int MAX_TOPWORDS = 24; - public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { + public static serverObjects respond(httpHeader header, serverObjects post, serverSwitch env) { final plasmaSwitchboard sb = (plasmaSwitchboard) env; final serverObjects prop = new serverObjects(); diff --git a/source/de/anomic/data/translator.java b/source/de/anomic/data/translator.java index 02e5b065f..4f29a0fa1 100644 --- a/source/de/anomic/data/translator.java +++ b/source/de/anomic/data/translator.java @@ -238,7 +238,7 @@ public class translator { return true; } - public static HashMap langMap(serverSwitch env) { + public static HashMap langMap(serverSwitch env) { String[] ms = env.getConfig("locale.lang", "").split(","); HashMap map = new HashMap(); int p; @@ -250,7 +250,7 @@ public class translator { return map; } - public static boolean changeLang(serverSwitch env, String langPath, String lang) { + public static boolean changeLang(serverSwitch env, String langPath, String lang) { if ((lang.equals("default")) || (lang.equals("default.lng"))) { env.setConfig("locale.language", "default"); return true; diff --git a/source/de/anomic/data/wiki/tokens/DefinitionListToken.java b/source/de/anomic/data/wiki/tokens/DefinitionListToken.java index b50ff545d..9fee61b13 100644 --- a/source/de/anomic/data/wiki/tokens/DefinitionListToken.java +++ b/source/de/anomic/data/wiki/tokens/DefinitionListToken.java @@ -49,7 +49,7 @@ package de.anomic.data.wiki.tokens; public class DefinitionListToken extends ListToken { - private static final String[] blockElements = { "dl", "dt", "dd" }; + //private static final String[] blockElements = { "dl", "dt", "dd" }; public DefinitionListToken() { super(';', null, null); diff --git a/source/de/anomic/http/httpd.java b/source/de/anomic/http/httpd.java index ce8581838..9d10f37ea 100644 --- a/source/de/anomic/http/httpd.java +++ b/source/de/anomic/http/httpd.java @@ -147,7 +147,7 @@ public final class httpd implements serverHandler { private final serverLog log = new serverLog("HTTPD"); // class methods - public httpd(serverSwitch s) { + public httpd(serverSwitch s) { // handler info httpd.switchboard = (plasmaSwitchboard)s; httpd.virtualHost = switchboard.getConfig("fileHost","localhost"); @@ -293,7 +293,7 @@ public final class httpd implements serverHandler { return persistent; } - public static int staticAdminAuthenticated(String authorization, serverSwitch sw){ + public static int staticAdminAuthenticated(String authorization, serverSwitch sw) { if (authorization==null) return 1; //if (authorization.length() < 6) return 1; // no authentication information given //authorization = authorization.trim().substring(6); diff --git a/source/de/anomic/http/httpdFileHandler.java b/source/de/anomic/http/httpdFileHandler.java index f73cca74f..3211722f1 100644 --- a/source/de/anomic/http/httpdFileHandler.java +++ b/source/de/anomic/http/httpdFileHandler.java @@ -118,7 +118,7 @@ public final class httpdFileHandler { private static final Properties mimeTable = new Properties(); private static final serverClassLoader provider; - private static serverSwitch switchboard; + private static serverSwitch switchboard; private static plasmaSwitchboard sb = plasmaSwitchboard.getSwitchboard(); private static File htRootPath = null; @@ -137,7 +137,7 @@ public final class httpdFileHandler { private static serverLog theLogger; static { - serverSwitch switchboard = plasmaSwitchboard.getSwitchboard(); + serverSwitch switchboard = plasmaSwitchboard.getSwitchboard(); useTemplateCache = switchboard.getConfig("enableTemplateCache","true").equalsIgnoreCase("true"); templateCache = (useTemplateCache)? new HashMap>() : new HashMap>(0); templateMethodCache = (useTemplateCache) ? new HashMap>() : new HashMap>(0); diff --git a/source/de/anomic/http/httpdRobotsTxtConfig.java b/source/de/anomic/http/httpdRobotsTxtConfig.java index d999406d6..3221f1fc1 100644 --- a/source/de/anomic/http/httpdRobotsTxtConfig.java +++ b/source/de/anomic/http/httpdRobotsTxtConfig.java @@ -102,7 +102,7 @@ public final class httpdRobotsTxtConfig { } } - public static httpdRobotsTxtConfig init(serverSwitch env) { + public static httpdRobotsTxtConfig init(serverSwitch env) { String cfg = env.getConfig(plasmaSwitchboard.ROBOTS_TXT, plasmaSwitchboard.ROBOTS_TXT_DEFAULT); if (cfg == null) return new httpdRobotsTxtConfig(); return new httpdRobotsTxtConfig(cfg.split(",")); diff --git a/source/de/anomic/http/httpdSwitchboard.java b/source/de/anomic/http/httpdSwitchboard.java deleted file mode 100644 index af8dfb8d6..000000000 --- a/source/de/anomic/http/httpdSwitchboard.java +++ /dev/null @@ -1,80 +0,0 @@ -// httpdSwitchboard.java -// ------------------------------------- -// (C) by Michael Peter Christen; mc@anomic.de -// first published on http://www.anomic.de -// Frankfurt, Germany, 2004 -// last major change: 15.07.2004 -// -// This program is free software; you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation; either version 2 of the License, or -// (at your option) any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -// -// Using this software in any meaning (reading, learning, copying, compiling, -// running) means that you agree that the Author(s) is (are) not responsible -// for cost, loss of data or any harm that may be caused directly or indirectly -// by usage of this softare or this documentation. The usage of this software -// is on your own risk. The installation and usage (starting/running) of this -// software may allow other people or application to access your computer and -// any attached devices and is highly dependent on the configuration of the -// software which must be done by the user of the software; the author(s) is -// (are) also not responsible for proper configuration and usage of the -// software, even if provoked by documentation provided together with -// the software. -// -// Any changes to this file according to the GPL as documented in the file -// gpl.txt aside this file in the shipment you received can be done to the -// lines that follows this copyright notice here, but changes must not be -// done inside the copyright notive above. A re-distribution must contain -// the intact and unchanged copyright notice. -// Contributions and changes to the program code must be marked as such. - -package de.anomic.http; - -import java.io.File; -import java.util.LinkedList; - -import de.anomic.server.serverAbstractSwitch; -import de.anomic.server.serverObjects; -import de.anomic.server.serverSwitch; - -public final class httpdSwitchboard extends serverAbstractSwitch implements serverSwitch { - - private final LinkedList cacheStack; - - public httpdSwitchboard(File rootPath, String initPath, String configPath, boolean applyPro) { - super(rootPath, initPath, configPath, applyPro); - cacheStack = new LinkedList(); - } - - public int queueSize() { - return cacheStack.size(); - } - - public void enQueue(Object job) { - cacheStack.addLast(job); - } - - public boolean deQueue() { - if (cacheStack.size() > 0) { - System.out.println("Process: " + cacheStack.removeFirst().toString()); - return true; - } - System.out.println("Process: queue is empty"); - return false; - } - - public serverObjects action(String actionName, serverObjects actionInput) { - return null; - } - -} diff --git a/source/de/anomic/kelondro/kelondroRowCollection.java b/source/de/anomic/kelondro/kelondroRowCollection.java index 396475cca..d2702cd28 100644 --- a/source/de/anomic/kelondro/kelondroRowCollection.java +++ b/source/de/anomic/kelondro/kelondroRowCollection.java @@ -602,7 +602,6 @@ public class kelondroRowCollection { // the collection has an ordering // and part of the ordered zone is inside the to-be-ordered zone int m = picMiddle(new int[]{L + (S - L) / 3, L + 2 * (S - L) / 3, S, (S + R - 1) / 2, R - 1}, 5); - assert S <= m; assert L <= m; assert m < R; return m; diff --git a/source/de/anomic/plasma/dbImport/AbstractImporter.java b/source/de/anomic/plasma/dbImport/AbstractImporter.java index f8dd29093..501632da1 100644 --- a/source/de/anomic/plasma/dbImport/AbstractImporter.java +++ b/source/de/anomic/plasma/dbImport/AbstractImporter.java @@ -36,7 +36,7 @@ public abstract class AbstractImporter extends Thread implements dbImporter{ /** * @see dbImporter#init(HashMap) */ - public void init() throws ImporterException { + public void init() { // initializing the logger and setting a more verbose thread name this.log = new serverLog("IMPORT_" + this.jobType + "_" + this.jobID); this.setName("IMPORT_" + this.jobType + "_" + this.jobID); diff --git a/source/de/anomic/plasma/plasmaSwitchboard.java b/source/de/anomic/plasma/plasmaSwitchboard.java index deffb71c9..7bbcd8a75 100644 --- a/source/de/anomic/plasma/plasmaSwitchboard.java +++ b/source/de/anomic/plasma/plasmaSwitchboard.java @@ -160,10 +160,10 @@ import de.anomic.yacy.yacySeed; import de.anomic.yacy.yacyURL; import de.anomic.yacy.yacyVersion; -public final class plasmaSwitchboard extends serverAbstractSwitch implements serverSwitch { +public final class plasmaSwitchboard extends serverAbstractSwitch implements serverSwitch { // load slots - public static int xstackCrawlSlots = 2000; + public static int xstackCrawlSlots = 2000; private int dhtTransferIndexCount = 100; @@ -381,7 +381,7 @@ public final class plasmaSwitchboard extends serverAbstractSwitch implements ser public static final String INDEXER_MEMPREREQ = "80_indexing_memprereq"; public static final String INDEXER_IDLESLEEP = "80_indexing_idlesleep"; public static final String INDEXER_BUSYSLEEP = "80_indexing_busysleep"; - public static final String INDEXER_METHOD_START = "deQueue"; + public static final String INDEXER_METHOD_START = "deQueueProcess"; public static final String INDEXER_METHOD_JOBCOUNT = "queueSize"; public static final String INDEXER_METHOD_FREEMEM = "deQueueFreeMem"; public static final String INDEXER_SLOTS = "indexer.slots"; @@ -1749,7 +1749,7 @@ public final class plasmaSwitchboard extends serverAbstractSwitch implements ser return sbQueue.size(); } - public void enQueue(Object job) { + public void enQueue(plasmaSwitchboardQueue.Entry job) { assert job != null; if (!(job instanceof plasmaSwitchboardQueue.Entry)) { System.out.println("Internal error at plasmaSwitchboard.enQueue: wrong job type"); @@ -1771,7 +1771,38 @@ public final class plasmaSwitchboard extends serverAbstractSwitch implements ser wordIndex.setMaxWordCount(newMaxCount); */ } - public boolean deQueue() { + public plasmaSwitchboardQueue.Entry deQueue() { + // getting the next entry from the indexing queue + plasmaSwitchboardQueue.Entry nextentry = null; + synchronized (sbQueue) { + // do one processing step + log.logFine("DEQUEUE: sbQueueSize=" + sbQueue.size() + + ", coreStackSize=" + crawlQueues.noticeURL.stackSize(plasmaCrawlNURL.STACK_TYPE_CORE) + + ", limitStackSize=" + crawlQueues.noticeURL.stackSize(plasmaCrawlNURL.STACK_TYPE_LIMIT) + + ", overhangStackSize=" + crawlQueues.noticeURL.stackSize(plasmaCrawlNURL.STACK_TYPE_OVERHANG) + + ", remoteStackSize=" + crawlQueues.noticeURL.stackSize(plasmaCrawlNURL.STACK_TYPE_REMOTE)); + try { + int sizeBefore = sbQueue.size(); + nextentry = sbQueue.pop(); + if (nextentry == null) { + log.logWarning("deQueue: null entry on queue stack."); + if (sbQueue.size() == sizeBefore) { + // this is a severe problem: because this time a null is returned, it means that this status will last forever + // to re-enable use of the sbQueue, it must be emptied completely + log.logSevere("deQueue: does not shrink after pop() == null. Emergency reset."); + sbQueue.clear(); + } + return null; + } + } catch (IOException e) { + log.logSevere("IOError in plasmaSwitchboard.deQueue: " + e.getMessage(), e); + return null; + } + return nextentry; + } + } + + public boolean deQueueProcess() { try { // work off fresh entries from the proxy or from the crawler if (onlineCaution()) { @@ -1779,11 +1810,13 @@ public final class plasmaSwitchboard extends serverAbstractSwitch implements ser return false; } - // flush some entries from the RAM cache - if (sbQueue.size() == 0) wordIndex.flushCacheSome(); // permanent flushing only if we are not busy - boolean doneSomething = false; - + + // flush some entries from the RAM cache + if (sbQueue.size() == 0) { + doneSomething = wordIndex.flushCacheSome() > 0; // permanent flushing only if we are not busy + } + // possibly delete entries from last chunk if ((this.dhtTransferChunk != null) && (this.dhtTransferChunk.getStatus() == plasmaDHTChunk.chunkStatus_COMPLETE)) { String deletedURLs = this.dhtTransferChunk.deleteTransferIndexes(); @@ -1811,55 +1844,28 @@ public final class plasmaSwitchboard extends serverAbstractSwitch implements ser checkInterruption(); // getting the next entry from the indexing queue - plasmaSwitchboardQueue.Entry nextentry = null; - synchronized (sbQueue) { - - if (sbQueue.size() == 0) { - //log.logFine("deQueue: nothing to do, queue is emtpy"); - return doneSomething; // nothing to do - } - - if (crawlStacker.size() >= getConfigLong(CRAWLSTACK_SLOTS, 2000)) { - log.logFine("deQueue: too many processes in stack crawl thread queue (" + "stackCrawlQueue=" + crawlStacker.size() + ")"); - return doneSomething; - } + if (sbQueue.size() == 0) { + //log.logFine("deQueue: nothing to do, queue is emtpy"); + return doneSomething; // nothing to do + } - - // if we were interrupted we should return now - if (Thread.currentThread().isInterrupted()) { - log.logFine("deQueue: thread was interrupted"); - return false; - } + if (crawlStacker.size() >= getConfigLong(CRAWLSTACK_SLOTS, 2000)) { + log.logFine("deQueue: too many processes in stack crawl thread queue (" + "stackCrawlQueue=" + crawlStacker.size() + ")"); + return doneSomething; + } - // do one processing step - log.logFine("DEQUEUE: sbQueueSize=" + sbQueue.size() + - ", coreStackSize=" + crawlQueues.noticeURL.stackSize(plasmaCrawlNURL.STACK_TYPE_CORE) + - ", limitStackSize=" + crawlQueues.noticeURL.stackSize(plasmaCrawlNURL.STACK_TYPE_LIMIT) + - ", overhangStackSize=" + crawlQueues.noticeURL.stackSize(plasmaCrawlNURL.STACK_TYPE_OVERHANG) + - ", remoteStackSize=" + crawlQueues.noticeURL.stackSize(plasmaCrawlNURL.STACK_TYPE_REMOTE)); - try { - int sizeBefore = sbQueue.size(); - nextentry = sbQueue.pop(); - if (nextentry == null) { - log.logWarning("deQueue: null entry on queue stack."); - if (sbQueue.size() == sizeBefore) { - // this is a severe problem: because this time a null is returned, it means that this status will last forever - // to re-enable use of the sbQueue, it must be emptied completely - log.logSevere("deQueue: does not shrink after pop() == null. Emergency reset."); - sbQueue.clear(); - } - return false; - } - } catch (IOException e) { - log.logSevere("IOError in plasmaSwitchboard.deQueue: " + e.getMessage(), e); - return doneSomething; - } + // if we were interrupted we should return now + if (Thread.currentThread().isInterrupted()) { + log.logFine("deQueue: thread was interrupted"); + return false; + } - synchronized (this.indexingTasksInProcess) { - this.indexingTasksInProcess.put(nextentry.urlHash(), nextentry); - } + plasmaSwitchboardQueue.Entry nextentry = deQueue(); + synchronized (this.indexingTasksInProcess) { + this.indexingTasksInProcess.put(nextentry.urlHash(), nextentry); } + // parse and index the resource processResourceStack(nextentry); return true; diff --git a/source/de/anomic/plasma/plasmaWordIndex.java b/source/de/anomic/plasma/plasmaWordIndex.java index f0cdf8c7c..4bc83b47d 100644 --- a/source/de/anomic/plasma/plasmaWordIndex.java +++ b/source/de/anomic/plasma/plasmaWordIndex.java @@ -225,13 +225,14 @@ public final class plasmaWordIndex implements indexRI { } } - public void flushCacheSome() { - flushCache(dhtOutCache, (dhtOutCache.size() > 3 * flushsize) ? flushsize : Math.min(flushsize, Math.max(1, dhtOutCache.size() / lowcachedivisor))); - flushCache(dhtInCache, (dhtInCache.size() > 3 * flushsize) ? flushsize : Math.min(flushsize, Math.max(1, dhtInCache.size() / lowcachedivisor))); + public int flushCacheSome() { + int fo = flushCache(dhtOutCache, (dhtOutCache.size() > 3 * flushsize) ? flushsize : Math.min(flushsize, Math.max(1, dhtOutCache.size() / lowcachedivisor))); + int fi = flushCache(dhtInCache, (dhtInCache.size() > 3 * flushsize) ? flushsize : Math.min(flushsize, Math.max(1, dhtInCache.size() / lowcachedivisor))); + return fo + fi; } - private void flushCache(indexRAMRI ram, int count) { - if (count <= 0) return; + private int flushCache(indexRAMRI ram, int count) { + if (count <= 0) return 0; busyCacheFlush = true; String wordHash; @@ -269,6 +270,7 @@ public final class plasmaWordIndex implements indexRI { collections.addMultipleEntries(containerList); //System.out.println("DEBUG-Finished flush of " + count + " entries from RAM to DB in " + (System.currentTimeMillis() - start) + " milliseconds"); busyCacheFlush = false; + return containerList.size(); } private static final int hour = 3600000; diff --git a/source/de/anomic/server/portForwarding/sch/serverPortForwardingSch.java b/source/de/anomic/server/portForwarding/sch/serverPortForwardingSch.java index a3157e9ca..c5c7ad4fe 100644 --- a/source/de/anomic/server/portForwarding/sch/serverPortForwardingSch.java +++ b/source/de/anomic/server/portForwarding/sch/serverPortForwardingSch.java @@ -78,7 +78,7 @@ public class serverPortForwardingSch implements serverPortForwarding{ /* ======================================================================== * Other object fields * ======================================================================== */ - private serverSwitch switchboard; + private serverSwitch switchboard; private String forwardingHost; private int forwardingHostPort; @@ -105,7 +105,7 @@ public class serverPortForwardingSch implements serverPortForwarding{ } public void init( - serverSwitch switchboard, + serverSwitch switchboard, String localHost, int localPort ) throws Exception { diff --git a/source/de/anomic/server/portForwarding/serverPortForwarding.java b/source/de/anomic/server/portForwarding/serverPortForwarding.java index 8facd2b90..64170a448 100644 --- a/source/de/anomic/server/portForwarding/serverPortForwarding.java +++ b/source/de/anomic/server/portForwarding/serverPortForwarding.java @@ -51,7 +51,7 @@ import java.io.IOException; import de.anomic.server.serverSwitch; public interface serverPortForwarding { - public void init(serverSwitch switchboard, String localHost, int localPort) throws Exception; + public void init(serverSwitch switchboard, String localHost, int localPort) throws Exception; public String getHost(); public int getPort(); diff --git a/source/de/anomic/server/portForwarding/upnp/serverPortForwardingUpnp.java b/source/de/anomic/server/portForwarding/upnp/serverPortForwardingUpnp.java index bfd7472e8..c390cc4a0 100644 --- a/source/de/anomic/server/portForwarding/upnp/serverPortForwardingUpnp.java +++ b/source/de/anomic/server/portForwarding/upnp/serverPortForwardingUpnp.java @@ -167,7 +167,7 @@ public class serverPortForwardingUpnp implements serverPortForwarding { return this.localHostPort; } - public void init(serverSwitch switchboard, String localHost, int localPort) + public void init(serverSwitch switchboard, String localHost, int localPort) throws Exception { try { this.log.logFine("Initializing port forwarding via UPnP ..."); diff --git a/source/de/anomic/server/serverAbstractSwitch.java b/source/de/anomic/server/serverAbstractSwitch.java index 1c072d22b..ea5ad604f 100644 --- a/source/de/anomic/server/serverAbstractSwitch.java +++ b/source/de/anomic/server/serverAbstractSwitch.java @@ -48,10 +48,11 @@ import java.util.HashMap; import java.util.Iterator; import java.util.Map; import java.util.TreeMap; +import java.util.concurrent.LinkedBlockingQueue; import de.anomic.server.logging.serverLog; -public abstract class serverAbstractSwitch implements serverSwitch { +public abstract class serverAbstractSwitch implements serverSwitch { private static final long maxTrackingTimeDefault = 1000 * 60 * 60; // store only access data from the last hour to save ram space @@ -68,6 +69,7 @@ public abstract class serverAbstractSwitch implements serverSwitch { private TreeMap workerThreads; private TreeMap switchActions; protected HashMap> accessTracker; // mappings from requesting host to an ArrayList of serverTrack-entries + private LinkedBlockingQueue cacheStack; public serverAbstractSwitch(File rootPath, String initPath, String configPath, boolean applyPro) { // we initialize the switchboard with a property file, @@ -76,10 +78,11 @@ public abstract class serverAbstractSwitch implements serverSwitch { // be deleted, but not the init file // the only attribute that will always be read from the init is the // file name of the config file + this.cacheStack = new LinkedBlockingQueue(); this.rootPath = rootPath; - configComment = "This is an automatically generated file, updated by serverAbstractSwitch and initialized by " + initPath; + this.configComment = "This is an automatically generated file, updated by serverAbstractSwitch and initialized by " + initPath; File initFile = new File(rootPath, initPath); - configFile = new File(rootPath, configPath); // propertiesFile(config); + this.configFile = new File(rootPath, configPath); // propertiesFile(config); new File(configFile.getParent()).mkdir(); // predefine init's @@ -471,10 +474,21 @@ public abstract class serverAbstractSwitch implements serverSwitch { return workerThreads.keySet().iterator(); } - abstract public int queueSize(); - abstract public void enQueue(Object job); - abstract public boolean deQueue(); - + public int queueSize() { + return cacheStack.size(); + } + + public E queuePeek() { + return cacheStack.peek(); + } + + public void enQueue(E job) { + cacheStack.add(job); + } + + public E deQueue() throws InterruptedException { + return cacheStack.take(); + } // authentification routines: diff --git a/source/de/anomic/server/serverCore.java b/source/de/anomic/server/serverCore.java index b880a8274..b91cf6b5a 100644 --- a/source/de/anomic/server/serverCore.java +++ b/source/de/anomic/server/serverCore.java @@ -118,7 +118,7 @@ public final class serverCore extends serverAbstractThread implements serverThre private int timeout; // connection time-out of the socket serverHandler handlerPrototype; // the command class (a serverHandler) - private serverSwitch switchboard; // the command class switchboard + private serverSwitch switchboard; // the command class switchboard HashMap denyHost; int commandMaxLength; private int maxBusySessions; @@ -178,7 +178,7 @@ public final class serverCore extends serverAbstractThread implements serverThre int timeout, boolean blockAttack, serverHandler handlerPrototype, - serverSwitch switchboard, + serverSwitch switchboard, int commandMaxLength ) { this.timeout = timeout; diff --git a/source/de/anomic/server/serverPlainSwitch.java b/source/de/anomic/server/serverPlainSwitch.java index 07892518f..99a56cfb3 100644 --- a/source/de/anomic/server/serverPlainSwitch.java +++ b/source/de/anomic/server/serverPlainSwitch.java @@ -28,28 +28,14 @@ package de.anomic.server; import java.io.File; -public class serverPlainSwitch extends serverAbstractSwitch implements serverSwitch { +public class serverPlainSwitch extends serverAbstractSwitch implements serverSwitch { public serverPlainSwitch(File rootPath, String initPath, String configPath, boolean applyPro) { super(rootPath, initPath, configPath, applyPro); } - - public int queueSize() { - // no queueing - return 0; - } - - public void enQueue(Object job) { - // no queueing: do nothing - } - - public boolean deQueue() { - // no queueing - return false; - } public serverObjects action(String actionName, serverObjects actionInput) { - // no acions + // no actions return null; } diff --git a/source/de/anomic/server/serverSwitch.java b/source/de/anomic/server/serverSwitch.java index 39df829f6..c58a09f5e 100644 --- a/source/de/anomic/server/serverSwitch.java +++ b/source/de/anomic/server/serverSwitch.java @@ -57,7 +57,7 @@ import java.util.TreeMap; import de.anomic.server.logging.serverLog; -public interface serverSwitch { +public interface serverSwitch { // the root path for the application public File getRootPath(); @@ -112,8 +112,9 @@ public interface serverSwitch { // to work off a queue job, use deQueue, which is meant to // work off exactly only one job, not all public int queueSize(); - public void enQueue(Object job); - public boolean deQueue(); // returns true if there had been dequeued anything + public E queuePeek(); // looks for next element in the queue, returns but not deletes it if there is one; returns null othervise + public void enQueue(E job); + public E deQueue() throws InterruptedException; // returns a FIFO entry from the stack, blocks until one element is available // authentification routines: sets and reads access attributes according to host addresses public void setAuthentify(InetAddress host, String user, String rigth); diff --git a/source/de/anomic/yacy/seedUpload/yacySeedUploadFile.java b/source/de/anomic/yacy/seedUpload/yacySeedUploadFile.java index 6c240fb31..54f4b46a0 100644 --- a/source/de/anomic/yacy/seedUpload/yacySeedUploadFile.java +++ b/source/de/anomic/yacy/seedUpload/yacySeedUploadFile.java @@ -56,7 +56,7 @@ public class yacySeedUploadFile implements yacySeedUploader { public static final String CONFIG_FILE_PATH = "seedFilePath"; - public String uploadSeedFile(serverSwitch sb, yacySeedDB seedDB, File seedFile) throws Exception { + public String uploadSeedFile(serverSwitch sb, yacySeedDB seedDB, File seedFile) throws Exception { String seedFilePath = ""; try { diff --git a/source/de/anomic/yacy/seedUpload/yacySeedUploadFtp.java b/source/de/anomic/yacy/seedUpload/yacySeedUploadFtp.java index a8b78cfc6..5720848b1 100644 --- a/source/de/anomic/yacy/seedUpload/yacySeedUploadFtp.java +++ b/source/de/anomic/yacy/seedUpload/yacySeedUploadFtp.java @@ -59,7 +59,7 @@ public class yacySeedUploadFtp implements yacySeedUploader { public static final String CONFIG_FTP_PASSWORD = "seedFTPPassword"; public static final String CONFIG_FTP_PATH = "seedFTPPath"; - public String uploadSeedFile (serverSwitch sb, yacySeedDB seedDB, File seedFile) throws Exception { + public String uploadSeedFile (serverSwitch sb, yacySeedDB seedDB, File seedFile) throws Exception { try { if (sb == null) throw new NullPointerException("Reference to serverSwitch must not be null."); if (seedDB == null) throw new NullPointerException("Reference to seedDB must not be null."); diff --git a/source/de/anomic/yacy/seedUpload/yacySeedUploadScp.java b/source/de/anomic/yacy/seedUpload/yacySeedUploadScp.java index 333f3d7fa..7137d4bd9 100644 --- a/source/de/anomic/yacy/seedUpload/yacySeedUploadScp.java +++ b/source/de/anomic/yacy/seedUpload/yacySeedUploadScp.java @@ -71,7 +71,7 @@ public class yacySeedUploadScp implements yacySeedUploader { public static final String CONFIG_SCP_PASSWORD = "seedScpPassword"; public static final String CONFIG_SCP_PATH = "seedScpPath"; - public String uploadSeedFile(serverSwitch sb, yacySeedDB seedDB, File seedFile) throws Exception { + public String uploadSeedFile(serverSwitch sb, yacySeedDB seedDB, File seedFile) throws Exception { try { if (sb == null) throw new NullPointerException("Reference to serverSwitch nut not be null."); if (seedDB == null) throw new NullPointerException("Reference to seedDB must not be null."); diff --git a/source/de/anomic/yacy/yacyCore.java b/source/de/anomic/yacy/yacyCore.java index e5f1ed1a8..99a4d7cb3 100644 --- a/source/de/anomic/yacy/yacyCore.java +++ b/source/de/anomic/yacy/yacyCore.java @@ -699,7 +699,7 @@ public class yacyCore { return saveSeedList(this.switchboard); } - public final String saveSeedList(serverSwitch sb) { + public final String saveSeedList(serverSwitch sb) { try { // return an error if this is not successful, and NULL if everything is fine String logt; diff --git a/source/de/anomic/yacy/yacyNetwork.java b/source/de/anomic/yacy/yacyNetwork.java index 9b93972e5..9764f3c4b 100644 --- a/source/de/anomic/yacy/yacyNetwork.java +++ b/source/de/anomic/yacy/yacyNetwork.java @@ -38,7 +38,7 @@ import de.anomic.tools.crypt; public class yacyNetwork { - public static final boolean authentifyRequest(serverObjects post, serverSwitch env) { + public static final boolean authentifyRequest(serverObjects post, serverSwitch env) { if ((post == null) || (env == null)) return false; // identify network @@ -67,7 +67,7 @@ public class yacyNetwork { return false; } - public static final serverObjects basicRequestPost(serverSwitch env, String targetHash) { + public static final serverObjects basicRequestPost(serverSwitch env, String targetHash) { // put in all the essentials for routing and network authentification // generate a session key serverObjects post = new serverObjects(); diff --git a/source/de/anomic/yacy/yacySeedDB.java b/source/de/anomic/yacy/yacySeedDB.java index ba6c0805b..091bd54e3 100644 --- a/source/de/anomic/yacy/yacySeedDB.java +++ b/source/de/anomic/yacy/yacySeedDB.java @@ -766,7 +766,7 @@ public final class yacySeedDB { } public String uploadCache(yacySeedUploader uploader, - serverSwitch sb, + serverSwitch sb, yacySeedDB seedDB, // String seedFTPServer, // String seedFTPAccount, diff --git a/source/de/anomic/yacy/yacySeedUploader.java b/source/de/anomic/yacy/yacySeedUploader.java index 0047b113a..817bbfdc6 100644 --- a/source/de/anomic/yacy/yacySeedUploader.java +++ b/source/de/anomic/yacy/yacySeedUploader.java @@ -48,7 +48,7 @@ import java.io.File; import de.anomic.server.serverSwitch; public interface yacySeedUploader { - public String uploadSeedFile(serverSwitch sb, yacySeedDB seedDB, File seedFile) throws Exception; + public String uploadSeedFile(serverSwitch sb, yacySeedDB seedDB, File seedFile) throws Exception; public String[] getConfigurationOptions(); public String[] getLibxDependencies(); }