Class JobManager
- java.lang.Object
-
- org.camunda.bpm.engine.impl.persistence.AbstractManager
-
- org.camunda.bpm.engine.impl.persistence.entity.JobManager
-
- All Implemented Interfaces:
Session
public class JobManager extends AbstractManager
- Author:
- Tom Baeyens, Daniel Meyer
-
-
Field Summary
Fields Modifier and Type Field Description static QueryOrderingProperty
JOB_DUEDATE_ORDERING_PROPERTY
static QueryOrderingProperty
JOB_PRIORITY_ORDERING_PROPERTY
static QueryOrderingProperty
JOB_TYPE_ORDERING_PROPERTY
-
Constructor Summary
Constructors Constructor Description JobManager()
-
Method Summary
-
Methods inherited from class org.camunda.bpm.engine.impl.persistence.AbstractManager
checkAuthorization, close, configureQuery, delete, deleteAuthorizations, deleteAuthorizationsForGroup, deleteAuthorizationsForUser, deleteDefaultAuthorizations, flush, getAttachmentManager, getAuthorizationManager, getBatchManager, getByteArrayManager, getCamundaFormDefinitionManager, getCaseDefinitionManager, getCaseExecutionManager, getCaseInstanceManager, getCommandContext, getCurrentAuthentication, getDbEntityManager, getDbSqlSession, getDecisionDefinitionManager, getDecisionRequirementsDefinitionManager, getDeploymentManager, getEventSubscriptionManager, getHistoricActivityInstanceManager, getHistoricBatchManager, getHistoricCaseActivityInstanceManager, getHistoricCaseInstanceManager, getHistoricDecisionInstanceManager, getHistoricDetailManager, getHistoricExternalTaskLogManager, getHistoricIdentityLinkManager, getHistoricIncidentManager, getHistoricJobLogManager, getHistoricProcessInstanceManager, getHistoricReportManager, getHistoricTaskInstanceManager, getHistoricVariableInstanceManager, getIdentityInfoManager, getIdentityLinkManager, getJobDefinitionManager, getJobManager, getProcessDefinitionManager, getProcessInstanceManager, getResourceAuthorizationProvider, getResourceManager, getSession, getTaskManager, getTaskReportManager, getTenantManager, getUserOperationLogManager, getVariableInstanceManager, insert, isAuthorizationEnabled, saveDefaultAuthorizations
-
-
-
-
Field Detail
-
JOB_PRIORITY_ORDERING_PROPERTY
public static QueryOrderingProperty JOB_PRIORITY_ORDERING_PROPERTY
-
JOB_TYPE_ORDERING_PROPERTY
public static QueryOrderingProperty JOB_TYPE_ORDERING_PROPERTY
-
JOB_DUEDATE_ORDERING_PROPERTY
public static QueryOrderingProperty JOB_DUEDATE_ORDERING_PROPERTY
-
-
Method Detail
-
updateJob
public void updateJob(JobEntity job)
-
insertJob
public void insertJob(JobEntity job)
-
deleteJob
public void deleteJob(JobEntity job)
-
deleteJob
public void deleteJob(JobEntity job, boolean fireDeleteEvent)
-
insertAndHintJobExecutor
public void insertAndHintJobExecutor(JobEntity jobEntity)
-
send
public void send(MessageEntity message)
-
schedule
public void schedule(TimerEntity timer)
-
hintJobExecutor
protected void hintJobExecutor(JobEntity job)
-
areInSameProcessInstance
protected boolean areInSameProcessInstance(JobEntity job1, JobEntity job2)
-
isJobPriorityInJobExecutorPriorityRange
protected boolean isJobPriorityInJobExecutorPriorityRange(long jobPriority)
-
cancelTimers
public void cancelTimers(ExecutionEntity execution)
-
findNextJobsToExecute
public List<AcquirableJobEntity> findNextJobsToExecute(Page page)
-
findJobsByProcessInstanceId
public List<JobEntity> findJobsByProcessInstanceId(String processInstanceId)
-
findUnlockedTimersByDuedate
public List<TimerEntity> findUnlockedTimersByDuedate(Date duedate, Page page)
-
findTimersByExecutionId
public List<TimerEntity> findTimersByExecutionId(String executionId)
-
findJobsByQueryCriteria
public List<Job> findJobsByQueryCriteria(JobQueryImpl jobQuery, Page page)
-
findDeploymentIdMappingsByQueryCriteria
public List<ImmutablePair<String,String>> findDeploymentIdMappingsByQueryCriteria(JobQueryImpl jobQuery)
-
findJobsByConfiguration
public List<JobEntity> findJobsByConfiguration(String jobHandlerType, String jobHandlerConfiguration, String tenantId)
-
findJobCountByQueryCriteria
public long findJobCountByQueryCriteria(JobQueryImpl jobQuery)
-
updateJobSuspensionStateById
public void updateJobSuspensionStateById(String jobId, SuspensionState suspensionState)
-
updateJobSuspensionStateByJobDefinitionId
public void updateJobSuspensionStateByJobDefinitionId(String jobDefinitionId, SuspensionState suspensionState)
-
updateJobSuspensionStateByProcessInstanceId
public void updateJobSuspensionStateByProcessInstanceId(String processInstanceId, SuspensionState suspensionState)
-
updateJobSuspensionStateByProcessDefinitionId
public void updateJobSuspensionStateByProcessDefinitionId(String processDefinitionId, SuspensionState suspensionState)
-
updateStartTimerJobSuspensionStateByProcessDefinitionId
public void updateStartTimerJobSuspensionStateByProcessDefinitionId(String processDefinitionId, SuspensionState suspensionState)
-
updateJobSuspensionStateByProcessDefinitionKey
public void updateJobSuspensionStateByProcessDefinitionKey(String processDefinitionKey, SuspensionState suspensionState)
-
updateJobSuspensionStateByProcessDefinitionKeyAndTenantId
public void updateJobSuspensionStateByProcessDefinitionKeyAndTenantId(String processDefinitionKey, String processDefinitionTenantId, SuspensionState suspensionState)
-
updateStartTimerJobSuspensionStateByProcessDefinitionKey
public void updateStartTimerJobSuspensionStateByProcessDefinitionKey(String processDefinitionKey, SuspensionState suspensionState)
-
updateStartTimerJobSuspensionStateByProcessDefinitionKeyAndTenantId
public void updateStartTimerJobSuspensionStateByProcessDefinitionKeyAndTenantId(String processDefinitionKey, String processDefinitionTenantId, SuspensionState suspensionState)
-
updateFailedJobRetriesByJobDefinitionId
public void updateFailedJobRetriesByJobDefinitionId(String jobDefinitionId, int retries, Date dueDate, boolean isDueDateSet)
-
updateJobPriorityByDefinitionId
public void updateJobPriorityByDefinitionId(String jobDefinitionId, long priority)
-
configureQuery
protected void configureQuery(JobQueryImpl query)
-
configureParameterizedQuery
protected ListQueryParameterObject configureParameterizedQuery(Object parameter)
-
isEnsureJobDueDateNotNull
protected boolean isEnsureJobDueDateNotNull()
-
isJobDue
protected boolean isJobDue(JobEntity job)
Sometimes we get a notification of a job that is not yet due, so we should not execute it immediately
-
-