Class TaskWorkerImpl

java.lang.Object
org.duracloud.mill.workman.TaskWorkerImpl
All Implemented Interfaces:
Runnable, TaskWorker

public class TaskWorkerImpl extends Object implements TaskWorker
It is responsible for executing a single TaskProcessor. During execution it makes sure to extend the visibility timeout of the item on the queue. the TaskProcessor.
Author:
Daniel Bernstein
  • Constructor Details

    • TaskWorkerImpl

      public TaskWorkerImpl(org.duracloud.common.queue.task.Task task, TaskProcessorFactory processorFactory, org.duracloud.common.queue.TaskQueue queue, org.duracloud.common.queue.TaskQueue deadLetterQueue, ScheduledThreadPoolExecutor timer)
      Parameters:
      task -
      processorFactory -
      queue -
  • Method Details

    • init

      protected void init()
      This method be called before run since it is possible that there may be significant delay between when the TaskWorker is initialized and when it is executed.
    • run

      public void run()
      Specified by:
      run in interface Runnable