Class StartedJobInfo

  • All Implemented Interfaces:
    Comparable<StartedJobInfo>

    public class StartedJobInfo
    extends Object
    implements Comparable<StartedJobInfo>
    This class is a simple bean storing information about a started job.

    This class is a persistent entity as per Berkeley DB JE DPL API.

    • Constructor Detail

      • StartedJobInfo

        public StartedJobInfo()
        Needed by BDB DPL.
      • StartedJobInfo

        public StartedJobInfo​(String harvestName,
                              long jobId)
        Instantiates all readable fields with default values.
        Parameters:
        harvestName - the name of the harvest
        jobId - the ID of the job
    • Method Detail

      • getJobId

        public long getJobId()
        Returns:
        the job ID.
      • getHarvestName

        public String getHarvestName()
        Returns:
        the harvest name.
      • getTimestamp

        public Date getTimestamp()
        Returns:
        the timestamp
      • getHostName

        public String getHostName()
        Returns:
        the name of the host on which Heritrix is crawling this job.
      • getHostUrl

        public String getHostUrl()
        Returns:
        the URL of the Heritrix admin console for the instance crawling this job.
      • getProgress

        public double getProgress()
        Returns:
        the crawl progress as a numeric percentage.
      • getQueuedFilesCount

        public long getQueuedFilesCount()
        Returns:
        the number of queued files reported by Heritrix.
      • getTotalQueuesCount

        public long getTotalQueuesCount()
        Returns:
        the number of queues reported by Heritrix.
      • getActiveQueuesCount

        public long getActiveQueuesCount()
        Returns:
        the number of active queues reported by Heritrix.
      • getRetiredQueuesCount

        public long getRetiredQueuesCount()
        Returns:
        the number of retired heritrix queues.
      • getExhaustedQueuesCount

        public long getExhaustedQueuesCount()
        Returns:
        the number of exhausted queues reported by Heritrix.
      • getElapsedTime

        public String getElapsedTime()
        Returns:
        the formatted duration of the crawl.
      • getElapsedSeconds

        public Long getElapsedSeconds()
        Returns:
        the duration of the crawl so far.
      • getAlertsCount

        public long getAlertsCount()
        Returns:
        the number of alerts raised by Heritrix.
      • getDownloadedFilesCount

        public long getDownloadedFilesCount()
        Returns:
        the number of downloaded URIs reported by Heritrix.
      • getCurrentProcessedKBPerSec

        public long getCurrentProcessedKBPerSec()
        Returns:
        the current download rate in KB/sec reported by Heritrix.
      • getProcessedKBPerSec

        public long getProcessedKBPerSec()
        Returns:
        the average download rate in KB/sec reported by Heritrix.
      • getCurrentProcessedDocsPerSec

        public double getCurrentProcessedDocsPerSec()
        Returns:
        the current download rate in URI/sec reported by Heritrix.
      • getProcessedDocsPerSec

        public double getProcessedDocsPerSec()
        Returns:
        the average download rate in URI/sec reported by Heritrix.
      • getActiveToeCount

        public int getActiveToeCount()
        Returns:
        the number of active processor threads reported by Heritrix.
      • chooseCompareCriteria

        public void chooseCompareCriteria​(StartedJobInfo.Criteria criteria)
        set the criteria used in the compareTo method that way we can decide how to sort StartedJobInfo.
        Parameters:
        criteria - the criteria we want to use
      • setHostUrl

        public void setHostUrl​(String hostUrl)
        Parameters:
        hostUrl - the hostUrl to set
      • setProgress

        public void setProgress​(double progress)
        Parameters:
        progress - the progress to set
      • setQueuedFilesCount

        public void setQueuedFilesCount​(long queuedFilesCount)
        Parameters:
        queuedFilesCount - the queuedFilesCount to set
      • setDownloadedFilesCount

        public void setDownloadedFilesCount​(long downloadedFilesCount)
        Parameters:
        downloadedFilesCount - the downloadedFilesCount to set
      • setTotalQueuesCount

        public void setTotalQueuesCount​(long totalQueuesCount)
        Parameters:
        totalQueuesCount - the totalQueuesCount to set
      • setActiveQueuesCount

        public void setActiveQueuesCount​(long activeQueuesCount)
        Parameters:
        activeQueuesCount - the activeQueuesCount to set
      • setExhaustedQueuesCount

        public void setExhaustedQueuesCount​(long exhaustedQueuesCount)
        Parameters:
        exhaustedQueuesCount - the exhaustedQueuesCount to set
      • setElapsedSeconds

        public void setElapsedSeconds​(long elapsedSeconds)
        Parameters:
        elapsedSeconds - the elapsedSeconds to set
      • setCurrentProcessedKBPerSec

        public void setCurrentProcessedKBPerSec​(long currentProcessedKBPerSec)
        Parameters:
        currentProcessedKBPerSec - the currentProcessedKBPerSec to set
      • setProcessedKBPerSec

        public void setProcessedKBPerSec​(long processedKBPerSec)
        Parameters:
        processedKBPerSec - the processedKBPerSec to set
      • setCurrentProcessedDocsPerSec

        public void setCurrentProcessedDocsPerSec​(double currentProcessedDocsPerSec)
        Parameters:
        currentProcessedDocsPerSec - the currentProcessedDocsPerSec to set
      • setProcessedDocsPerSec

        public void setProcessedDocsPerSec​(double processedDocsPerSec)
        Parameters:
        processedDocsPerSec - the processedDocsPerSec to set
      • setActiveToeCount

        public void setActiveToeCount​(int activeToeCount)
        Parameters:
        activeToeCount - the activeToeCount to set
      • setAlertsCount

        public void setAlertsCount​(long alertsCount)
        Parameters:
        alertsCount - the alertsCount to set
      • setTimestamp

        public void setTimestamp​(Date timestamp)
        Parameters:
        timestamp - the timestamp to set
      • setRetiredQueuesCount

        public void setRetiredQueuesCount​(long retiredQueuesCount)
        Parameters:
        retiredQueuesCount - the retiredQueuesCount to set
      • getInactiveQueuesCount

        public long getInactiveQueuesCount()
      • setInactiveQueuesCount

        public void setInactiveQueuesCount​(long inactiveQueuesCount)