Class FessIntervalController
java.lang.Object
org.codelibs.fess.crawler.interval.impl.AbstractIntervalController
org.codelibs.fess.crawler.interval.impl.DefaultIntervalController
org.codelibs.fess.crawler.interval.FessIntervalController
- All Implemented Interfaces:
org.codelibs.fess.crawler.interval.IntervalController
public class FessIntervalController
extends org.codelibs.fess.crawler.interval.impl.DefaultIntervalController
FessIntervalController extends DefaultIntervalController to provide
Fess-specific interval control functionality for web crawling operations.
This controller manages delays and timing for various crawling states
including processing delays, queue waiting times, and new URL discovery.
-
Field Summary
Fields inherited from class org.codelibs.fess.crawler.interval.impl.DefaultIntervalController
delayMillisAfterProcessing, delayMillisAtNoUrlInQueue, delayMillisBeforeProcessing, delayMillisForWaitingNewUrlFields inherited from class org.codelibs.fess.crawler.interval.impl.AbstractIntervalController
ignoreExceptionFields inherited from interface org.codelibs.fess.crawler.interval.IntervalController
NO_URL_IN_QUEUE, POST_PROCESSING, PRE_PROCESSING, WAIT_NEW_URL -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidDelays the crawler while waiting for new URLs to be available.longGets the delay time in milliseconds after processing a URL.longGets the delay time in milliseconds when there are no URLs in the queue.longGets the delay time in milliseconds before processing a URL.longGets the delay time in milliseconds for waiting for new URLs.voidsetDelayMillisAfterProcessing(long delayMillisAfterProcessing) Sets the delay time in milliseconds after processing a URL.voidsetDelayMillisAtNoUrlInQueue(long delayMillisAtNoUrlInQueue) Sets the delay time in milliseconds when there are no URLs in the queue.voidsetDelayMillisBeforeProcessing(long delayMillisBeforeProcessing) Sets the delay time in milliseconds before processing a URL.voidsetDelayMillisForWaitingNewUrl(long delayMillisForWaitingNewUrl) Sets the delay time in milliseconds for waiting for new URLs.Methods inherited from class org.codelibs.fess.crawler.interval.impl.DefaultIntervalController
delayAfterProcessing, delayAtNoUrlInQueue, delayBeforeProcessingMethods inherited from class org.codelibs.fess.crawler.interval.impl.AbstractIntervalController
delay, isIgnoreException, setIgnoreException
-
Constructor Details
-
FessIntervalController
public FessIntervalController()Default constructor.
-
-
Method Details
-
getDelayMillisAfterProcessing
public long getDelayMillisAfterProcessing()Gets the delay time in milliseconds after processing a URL.- Overrides:
getDelayMillisAfterProcessingin classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController- Returns:
- the delay time in milliseconds after processing
-
setDelayMillisAfterProcessing
public void setDelayMillisAfterProcessing(long delayMillisAfterProcessing) Sets the delay time in milliseconds after processing a URL.- Overrides:
setDelayMillisAfterProcessingin classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController- Parameters:
delayMillisAfterProcessing- the delay time in milliseconds after processing
-
getDelayMillisAtNoUrlInQueue
public long getDelayMillisAtNoUrlInQueue()Gets the delay time in milliseconds when there are no URLs in the queue.- Overrides:
getDelayMillisAtNoUrlInQueuein classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController- Returns:
- the delay time in milliseconds when no URLs are available
-
setDelayMillisAtNoUrlInQueue
public void setDelayMillisAtNoUrlInQueue(long delayMillisAtNoUrlInQueue) Sets the delay time in milliseconds when there are no URLs in the queue.- Overrides:
setDelayMillisAtNoUrlInQueuein classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController- Parameters:
delayMillisAtNoUrlInQueue- the delay time in milliseconds when no URLs are available
-
getDelayMillisBeforeProcessing
public long getDelayMillisBeforeProcessing()Gets the delay time in milliseconds before processing a URL.- Overrides:
getDelayMillisBeforeProcessingin classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController- Returns:
- the delay time in milliseconds before processing
-
setDelayMillisBeforeProcessing
public void setDelayMillisBeforeProcessing(long delayMillisBeforeProcessing) Sets the delay time in milliseconds before processing a URL.- Overrides:
setDelayMillisBeforeProcessingin classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController- Parameters:
delayMillisBeforeProcessing- the delay time in milliseconds before processing
-
getDelayMillisForWaitingNewUrl
public long getDelayMillisForWaitingNewUrl()Gets the delay time in milliseconds for waiting for new URLs.- Overrides:
getDelayMillisForWaitingNewUrlin classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController- Returns:
- the delay time in milliseconds for waiting for new URLs
-
setDelayMillisForWaitingNewUrl
public void setDelayMillisForWaitingNewUrl(long delayMillisForWaitingNewUrl) Sets the delay time in milliseconds for waiting for new URLs.- Overrides:
setDelayMillisForWaitingNewUrlin classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController- Parameters:
delayMillisForWaitingNewUrl- the delay time in milliseconds for waiting for new URLs
-
delayForWaitingNewUrl
protected void delayForWaitingNewUrl()Delays the crawler while waiting for new URLs to be available. This method calibrates CPU load, checks crawler status, applies interval control rules, and then calls the parent implementation. All operations are wrapped in exception handling to ensure robustness in test and production environments.- Overrides:
delayForWaitingNewUrlin classorg.codelibs.fess.crawler.interval.impl.DefaultIntervalController
-