Class WebFsIndexHelper

java.lang.Object
org.codelibs.fess.helper.WebFsIndexHelper

public class WebFsIndexHelper extends Object
Helper class for web and file system crawling and indexing operations. Manages the crawling process for both web configurations and file configurations, coordinating multiple crawler threads and handling indexing operations.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final List<org.codelibs.fess.crawler.Crawler>
    Synchronized list of active crawlers.
    protected int
    Thread priority for crawler operations.
    protected long
    Interval time in milliseconds between crawling executions.
    protected int
    Thread priority for index updater operations.
    protected long
    Maximum number of URLs to access during crawling.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Default constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    crawl(String sessionId, List<String> webConfigIdList, List<String> fileConfigIdList)
    Initiates crawling for specified web and file configurations.
    protected void
    Deletes crawl data for the specified session ID.
    protected void
    doCrawl(String sessionId, List<org.codelibs.fess.opensearch.config.exentity.WebConfig> webConfigList, List<org.codelibs.fess.opensearch.config.exentity.FileConfig> fileConfigList)
    Performs the actual crawling operation for the provided configurations.
    protected List<org.codelibs.fess.opensearch.config.exentity.BoostDocumentRule>
    Gets the list of available boost document rules.
    void
    setCrawlerPriority(int crawlerPriority)
    Sets the thread priority for crawler operations.
    void
    setCrawlingExecutionInterval(long crawlingExecutionInterval)
    Sets the interval time between crawling executions.
    void
    setIndexUpdaterPriority(int indexUpdaterPriority)
    Sets the thread priority for index updater operations.
    void
    setMaxAccessCount(long maxAccessCount)
    Sets the maximum number of URLs to access during crawling.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • maxAccessCount

      protected long maxAccessCount
      Maximum number of URLs to access during crawling.
    • crawlingExecutionInterval

      protected long crawlingExecutionInterval
      Interval time in milliseconds between crawling executions.
    • indexUpdaterPriority

      protected int indexUpdaterPriority
      Thread priority for index updater operations.
    • crawlerPriority

      protected int crawlerPriority
      Thread priority for crawler operations.
    • crawlerList

      protected final List<org.codelibs.fess.crawler.Crawler> crawlerList
      Synchronized list of active crawlers.
  • Constructor Details

    • WebFsIndexHelper

      public WebFsIndexHelper()
      Default constructor.
  • Method Details

    • crawl

      public void crawl(String sessionId, List<String> webConfigIdList, List<String> fileConfigIdList)
      Initiates crawling for specified web and file configurations.
      Parameters:
      sessionId - The session ID for this crawling operation
      webConfigIdList - List of web configuration IDs to crawl, null for all
      fileConfigIdList - List of file configuration IDs to crawl, null for all
    • doCrawl

      protected void doCrawl(String sessionId, List<org.codelibs.fess.opensearch.config.exentity.WebConfig> webConfigList, List<org.codelibs.fess.opensearch.config.exentity.FileConfig> fileConfigList)
      Performs the actual crawling operation for the provided configurations.
      Parameters:
      sessionId - The session ID for this crawling operation
      webConfigList - List of web configurations to crawl
      fileConfigList - List of file configurations to crawl
    • getAvailableBoostDocumentRuleList

      protected List<org.codelibs.fess.opensearch.config.exentity.BoostDocumentRule> getAvailableBoostDocumentRuleList()
      Gets the list of available boost document rules.
      Returns:
      List of boost document rules that are currently available
    • deleteCrawlData

      protected void deleteCrawlData(String sid)
      Deletes crawl data for the specified session ID.
      Parameters:
      sid - The session ID whose crawl data should be deleted
    • setMaxAccessCount

      public void setMaxAccessCount(long maxAccessCount)
      Sets the maximum number of URLs to access during crawling.
      Parameters:
      maxAccessCount - The maximum access count
    • setCrawlingExecutionInterval

      public void setCrawlingExecutionInterval(long crawlingExecutionInterval)
      Sets the interval time between crawling executions.
      Parameters:
      crawlingExecutionInterval - The crawling execution interval in milliseconds
    • setIndexUpdaterPriority

      public void setIndexUpdaterPriority(int indexUpdaterPriority)
      Sets the thread priority for index updater operations.
      Parameters:
      indexUpdaterPriority - The index updater thread priority
    • setCrawlerPriority

      public void setCrawlerPriority(int crawlerPriority)
      Sets the thread priority for crawler operations.
      Parameters:
      crawlerPriority - The crawler thread priority