Class AbstractMessageBasedJobManager
- java.lang.Object
-
- org.flowable.job.service.impl.asyncexecutor.DefaultJobManager
-
- org.flowable.job.service.impl.asyncexecutor.message.AbstractMessageBasedJobManager
-
- All Implemented Interfaces:
JobManager
public abstract class AbstractMessageBasedJobManager extends DefaultJobManager
Abstract class that contains the main logic to send information about an async history data job to a message queue. Subclasses are responsible for implementing the actual sending logic.- Author:
- Joram Barrez
-
-
Field Summary
-
Fields inherited from class org.flowable.job.service.impl.asyncexecutor.DefaultJobManager
CYCLE_TYPE, jobServiceConfiguration
-
-
Constructor Summary
Constructors Constructor Description AbstractMessageBasedJobManager()AbstractMessageBasedJobManager(JobServiceConfiguration jobServiceConfiguration)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidprepareAndSendMessage(JobInfo job)protected abstract voidsendMessage(JobInfo job)Subclasses need to implement this method: it should contain the actual sending of the message using the job data provided in the parameter.protected voidtriggerAsyncHistoryExecutorIfNeeded(HistoryJobEntity jobEntity)protected voidtriggerExecutorIfNeeded(JobEntity jobEntity)voidunacquire(JobInfo job)Unacquires a job, meaning that this job was previously locked, and it is now freed to be acquired by other executor nodes.voidunacquireWithDecrementRetries(JobInfo job, Throwable throwable)Unacquires a job, meaning that this job was previously locked, and it is now freed to be acquired by other executor nodes.-
Methods inherited from class org.flowable.job.service.impl.asyncexecutor.DefaultJobManager
activateSuspendedJob, bulkMoveTimerJobsToExecutableJobs, callHistoryJobProcessors, callJobProcessors, copyHistoryJobInfo, copyHistoryJobProperties, copyJobInfo, createAsyncHistoryHintListeners, createAsyncJob, createDeadLetterJobFromHistoryJob, createDeadLetterJobFromOtherJob, createExecutableJobFromOtherJob, createExecutableJobFromOtherJob, createExternalWorkerJobFromOtherJob, createHintListeners, createSuspendedJobFromOtherJob, createTimerJobFromOtherJob, execute, executeHistoryJob, executeHistoryJobHandler, executeJobHandler, executeMessageJob, executeTimerJob, fillDefaultAsyncJobInfo, getAsyncExecutor, getAsyncHistoryExecutor, getBusinessCalendarName, getBusinessCalendarName, getCommandContext, getExceptionStacktrace, getJobServiceConfiguration, hintAsyncExecutor, hintAsyncHistoryExecutor, internalCreateAsyncJob, internalCreateLockedAsyncJob, isAsyncExecutorActive, isAsyncExecutorRemainingCapacitySufficient, isAsyncHistoryExecutorActive, isExecutorActive, isValidTime, moveDeadLetterJobToExecutableJob, moveDeadLetterJobToHistoryJob, moveExternalWorkerJobToExecutableJob, moveJobToDeadLetterJob, moveJobToSuspendedJob, moveJobToTimerJob, moveTimerJobToExecutableJob, scheduleAsyncJob, scheduleHistoryJob, scheduleTimerJob, sendMoveToDeadletterEvent, setJobServiceConfiguration, setLockTimeAndOwner
-
-
-
-
Constructor Detail
-
AbstractMessageBasedJobManager
public AbstractMessageBasedJobManager()
-
AbstractMessageBasedJobManager
public AbstractMessageBasedJobManager(JobServiceConfiguration jobServiceConfiguration)
-
-
Method Detail
-
triggerExecutorIfNeeded
protected void triggerExecutorIfNeeded(JobEntity jobEntity)
- Overrides:
triggerExecutorIfNeededin classDefaultJobManager
-
triggerAsyncHistoryExecutorIfNeeded
protected void triggerAsyncHistoryExecutorIfNeeded(HistoryJobEntity jobEntity)
- Overrides:
triggerAsyncHistoryExecutorIfNeededin classDefaultJobManager
-
unacquire
public void unacquire(JobInfo job)
Description copied from interface:JobManagerUnacquires a job, meaning that this job was previously locked, and it is now freed to be acquired by other executor nodes.- Specified by:
unacquirein interfaceJobManager- Overrides:
unacquirein classDefaultJobManager
-
unacquireWithDecrementRetries
public void unacquireWithDecrementRetries(JobInfo job, Throwable throwable)
Description copied from interface:JobManagerUnacquires a job, meaning that this job was previously locked, and it is now freed to be acquired by other executor nodes.- Specified by:
unacquireWithDecrementRetriesin interfaceJobManager- Overrides:
unacquireWithDecrementRetriesin classDefaultJobManager
-
prepareAndSendMessage
protected void prepareAndSendMessage(JobInfo job)
-
sendMessage
protected abstract void sendMessage(JobInfo job)
Subclasses need to implement this method: it should contain the actual sending of the message using the job data provided in the parameter.
-
-