From f8714087292bf1840a16d0c702cac62800d640b5 Mon Sep 17 00:00:00 2001 From: theli Date: Thu, 3 Nov 2005 08:32:43 +0000 Subject: [PATCH] *) sharedBlacklist_p.java - Setting Pragma: no-cache - increasing timeout to 12 sec. git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@1019 6c8d7289-2bf4-0310-a012-ef5d649a1542 --- htroot/sharedBlacklist_p.java | 13 +++++++++---- htroot/yacy/list.java | 3 ++- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/htroot/sharedBlacklist_p.java b/htroot/sharedBlacklist_p.java index 901a92ec1..8696c262b 100644 --- a/htroot/sharedBlacklist_p.java +++ b/htroot/sharedBlacklist_p.java @@ -140,10 +140,15 @@ public class sharedBlacklist_p { //Name = "RootServer"; //Make Adresse - address = "http://" + IP + ":" + Port + "/yacy/list.html?col=black"; - try { - otherBlacklist = httpc.wget(new URL(address), 6000, null, null, switchboard.remoteProxyConfig); //get List - } catch (Exception e) {} + address = "http://" + IP + ":" + Port + "/yacy/list.html?col=black"; + try { + httpHeader reqHeader = new httpHeader(); + reqHeader.put(httpHeader.PRAGMA,"no-cache"); + reqHeader.put(httpHeader.CACHE_CONTROL,"no-cache"); + + // get List + otherBlacklist = httpc.wget(new URL(address), 12000, null, null, switchboard.remoteProxyConfig,reqHeader); + } catch (Exception e) {} //Make HTML-Optionlist with retrieved items for(i = 0; i <= (otherBlacklist.size() -1); i++){ diff --git a/htroot/yacy/list.java b/htroot/yacy/list.java index 85bd7c14c..4ec1ef83c 100644 --- a/htroot/yacy/list.java +++ b/htroot/yacy/list.java @@ -77,7 +77,8 @@ public final class list { if(filenamesarray.length >0){ for(int i = 0;i <= filenamesarray.length -1; i++){ filename = filenamesarray[i]; - out.append(listManager.getListString(new File(listsPath,filename).toString(), false)).append(serverCore.crlfString); + out.append(listManager.getListString(new File(listsPath,filename).toString(), false)) + .append(serverCore.crlfString); } } // if filenamesarray.length > 0