Package com.hpe.caf.worker.markup
Class MarkupWorkerFactory
java.lang.Object
com.hpe.caf.worker.AbstractWorkerFactory<MarkupWorkerConfiguration,MarkupWorkerTask>
com.hpe.caf.worker.markup.MarkupWorkerFactory
- All Implemented Interfaces:
com.hpe.caf.api.HealthReporter,com.hpe.caf.api.worker.WorkerFactory
public class MarkupWorkerFactory
extends com.hpe.caf.worker.AbstractWorkerFactory<MarkupWorkerConfiguration,MarkupWorkerTask>
Factory class for creating a MarkupWorker.
-
Constructor Summary
ConstructorsConstructorDescriptionMarkupWorkerFactory(com.hpe.caf.api.ConfigurationSource configSource, com.hpe.caf.api.worker.DataStore store, com.hpe.caf.api.Codec codec) -
Method Summary
Modifier and TypeMethodDescriptioncom.hpe.caf.api.worker.WorkercreateWorker(MarkupWorkerTask task, com.hpe.caf.api.worker.WorkerTaskData workerTaskData) Create a worker given a task, using DataStore, ConfiguratonSource and Codec passed in the constructor.protected intprotected Stringintcom.hpe.caf.api.HealthResultMarkupWorkerFactory is responsible for calling the health-check to view the status of the worker and this is displayed on Marathon.Methods inherited from class com.hpe.caf.worker.AbstractWorkerFactory
getCodec, getConfiguration, getDataStore, getWorker, getWorkerConfiguration, verifyWorkerTask, verifyWorkerTaskAndSetResponseMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.hpe.caf.api.worker.WorkerFactory
getWorker, shutdown
-
Constructor Details
-
MarkupWorkerFactory
public MarkupWorkerFactory(com.hpe.caf.api.ConfigurationSource configSource, com.hpe.caf.api.worker.DataStore store, com.hpe.caf.api.Codec codec) throws com.hpe.caf.api.worker.WorkerException - Throws:
com.hpe.caf.api.worker.WorkerException
-
-
Method Details
-
getWorkerName
- Specified by:
getWorkerNamein classcom.hpe.caf.worker.AbstractWorkerFactory<MarkupWorkerConfiguration,MarkupWorkerTask>
-
getWorkerApiVersion
protected int getWorkerApiVersion()- Specified by:
getWorkerApiVersionin classcom.hpe.caf.worker.AbstractWorkerFactory<MarkupWorkerConfiguration,MarkupWorkerTask>
-
createWorker
public com.hpe.caf.api.worker.Worker createWorker(MarkupWorkerTask task, com.hpe.caf.api.worker.WorkerTaskData workerTaskData) throws com.hpe.caf.api.worker.InvalidTaskException Create a worker given a task, using DataStore, ConfiguratonSource and Codec passed in the constructor.- Specified by:
createWorkerin classcom.hpe.caf.worker.AbstractWorkerFactory<MarkupWorkerConfiguration,MarkupWorkerTask> - Parameters:
task-workerTaskData-- Returns:
- MarkupWorker
- Throws:
com.hpe.caf.api.worker.InvalidTaskException
-
getInvalidTaskQueue
-
getWorkerThreads
public int getWorkerThreads() -
healthCheck
public com.hpe.caf.api.HealthResult healthCheck()MarkupWorkerFactory is responsible for calling the health-check to view the status of the worker and this is displayed on Marathon.- Returns:
- HealthResult
-