Class GenerateThumbnailJob

java.lang.Object
org.codelibs.fess.job.ExecJob
org.codelibs.fess.job.GenerateThumbnailJob

public class GenerateThumbnailJob extends ExecJob
Job class for generating thumbnails for documents in the search engine. This job executes the ThumbnailGenerator process as a separate JVM process to create thumbnail images for supported document types.
  • Field Details

    • numOfThreads

      protected int numOfThreads
      Number of threads to use for thumbnail generation.
    • cleanup

      protected boolean cleanup
      Flag indicating whether to perform cleanup operations.
  • Constructor Details

    • GenerateThumbnailJob

      public GenerateThumbnailJob()
      Default constructor for the GenerateThumbnailJob.
  • Method Details

    • numOfThreads

      public GenerateThumbnailJob numOfThreads(int numOfThreads)
      Sets the number of threads to use for thumbnail generation.
      Parameters:
      numOfThreads - the number of threads
      Returns:
      this job instance for method chaining
    • cleanup

      public GenerateThumbnailJob cleanup()
      Enables cleanup operations for this job.
      Returns:
      this job instance for method chaining
    • execute

      public String execute()
      Description copied from class: ExecJob
      Executes the job and returns the result as a string. This method contains the main business logic for the specific job implementation.
      Specified by:
      execute in class ExecJob
      Returns:
      the execution result message or summary
    • executeThumbnailGenerator

      protected void executeThumbnailGenerator()
      Executes the thumbnail generator process. Sets up the classpath, JVM options, and command line arguments to launch the ThumbnailGenerator in a separate process.
      Throws:
      JobProcessingException - if the thumbnail generation process fails
    • getExecuteType

      protected String getExecuteType()
      Description copied from class: ExecJob
      Returns the execution type identifier for this job. This type is used for classpath construction, configuration, and logging purposes.
      Specified by:
      getExecuteType in class ExecJob
      Returns:
      the execution type (e.g., "crawler", "suggest", etc.)