public final class DocumentMessageProcessor extends Object implements com.hpe.caf.api.worker.Worker
| Constructor and Description |
|---|
DocumentMessageProcessor(ApplicationImpl application,
DocumentWorker documentWorker,
com.hpe.caf.api.worker.WorkerTaskData workerTask)
Constructs the DocumentMessageProcessor object, which is used to process a single worker message.
|
| Modifier and Type | Method and Description |
|---|---|
com.hpe.caf.api.worker.WorkerResponse |
doWork() |
com.hpe.caf.api.worker.WorkerResponse |
getGeneralFailureResult(Throwable t) |
int |
getWorkerApiVersion() |
String |
getWorkerIdentifier() |
public DocumentMessageProcessor(ApplicationImpl application, DocumentWorker documentWorker, com.hpe.caf.api.worker.WorkerTaskData workerTask) throws com.hpe.caf.api.worker.TaskRejectedException, com.hpe.caf.api.worker.InvalidTaskException
application - the global data for the workerdocumentWorker - the actual implementation of the workerworkerTask - the task which the worker should performcom.hpe.caf.api.worker.TaskRejectedException - if the task can't be handled right now but should be retriedcom.hpe.caf.api.worker.InvalidTaskException - if there is something wrong with the task which means that if will always failpublic final com.hpe.caf.api.worker.WorkerResponse doWork()
throws InterruptedException,
com.hpe.caf.api.worker.TaskRejectedException
doWork in interface com.hpe.caf.api.worker.WorkerInterruptedExceptioncom.hpe.caf.api.worker.TaskRejectedExceptionpublic final String getWorkerIdentifier()
getWorkerIdentifier in interface com.hpe.caf.api.worker.Workerpublic final int getWorkerApiVersion()
getWorkerApiVersion in interface com.hpe.caf.api.worker.Workerpublic final com.hpe.caf.api.worker.WorkerResponse getGeneralFailureResult(Throwable t)
getGeneralFailureResult in interface com.hpe.caf.api.worker.WorkerCopyright © 2016–2021 EntIT Software LLC, a Micro Focus company. All rights reserved.