// returns a crawl entry from the stack and ensures minimum delta times
filltop(delay,600000,false);
filltop(delay,60000,false);
filltop(delay,10000,false);
filltop(delay,6000,false);
filltop(delay,3000,false);
filltop(delay,1000,false);
filltop(delay,-600000,false);
filltop(delay,-60000,false);
filltop(delay,-10000,false);
filltop(delay,-6000,false);
filltop(delay,-4000,false);
filltop(delay,-3000,false);
filltop(delay,-2000,false);
filltop(delay,-1000,false);
filltop(delay,-500,false);
filltop(delay,0,true);
Stringresult=null;// the result
@ -306,16 +309,29 @@ public class Balancer {
// in best case, this should never happen if the balancer works propertly
// this is only to protection against the worst case, where the crawler could
// behave in a DoS-manner
Log.logInfo("BALANCER","forcing crawl-delay of "+sleeptime+" milliseconds for "+crawlEntry.url().getHost()+((sleeptime>Math.max(minimumLocalDelta,minimumGlobalDelta))?" (forced latency)":""));
Log.logInfo("BALANCER","forcing crawl-delay of "+(sleeptime/1000)+" seconds for "+crawlEntry.url().getHost()+((sleeptime>Math.max(minimumLocalDelta,minimumGlobalDelta))?" (forced latency)":""));