Interface DivertedTaskHandler


public interface DivertedTaskHandler
A worker should implement this interface if it is capable of evaluating task messages that have been diverted (maybe because the worker's input queue is different from the target/to queue in the task message), and deciding what to do with them.
  • Method Details

    • handleDivertedTask

      DivertedTaskAction handleDivertedTask(TaskMessage tm, TaskInformation taskInformation, Map<String,Object> headers, Codec codec, JobStatus jobStatus, WorkerCallback callback)
      Examines the task message and decides what to do with it.
      Parameters:
      tm - the task message
      taskInformation - the reference to the message this task arrived on
      headers - the map of key/value paired headers to be stamped on the message
      codec - the Codec that can be used to serialise/deserialise data
      jobStatus - the job status as returned by the status check URL
      callback - worker callback to enact the diverted action determined by the worker
      Returns:
      the diverted task action to be taken by the worker