Class JobAcquisitionContext
- java.lang.Object
-
- org.camunda.bpm.engine.impl.jobexecutor.JobAcquisitionContext
-
public class JobAcquisitionContext extends Object
- Author:
- Thorben Lindhauer
-
-
Field Summary
Fields Modifier and Type Field Description protected Map<String,AcquiredJobs>
acquiredJobsByEngine
protected Exception
acquisitionException
protected long
acquisitionTime
protected Map<String,List<List<String>>>
additionalJobBatchesByEngine
protected boolean
isJobAdded
protected Map<String,List<List<String>>>
rejectedJobBatchesByEngine
-
Constructor Summary
Constructors Constructor Description JobAcquisitionContext()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
areAllEnginesIdle()
Map<String,AcquiredJobs>
getAcquiredJobsByEngine()
Jobs that were acquired in the current acquisition cycle.Exception
getAcquisitionException()
long
getAcquisitionTime()
Map<String,List<List<String>>>
getAdditionalJobsByEngine()
Jobs that have been acquired in previous cycles and are supposed to be re-submitted for executionMap<String,List<List<String>>>
getRejectedJobsByEngine()
Jobs that were rejected from execution in the acquisition cycle due to lacking execution resources.boolean
hasJobAcquisitionLockFailureOccurred()
true if at least one job could not be locked, regardless of engineboolean
isJobAdded()
void
reset()
void
setAcquisitionException(Exception e)
void
setAcquisitionTime(long acquisitionTime)
void
setJobAdded(boolean isJobAdded)
void
submitAcquiredJobs(String engineName, AcquiredJobs acquiredJobs)
void
submitAdditionalJobBatch(String engineName, List<String> jobIds)
void
submitRejectedBatch(String engineName, List<String> jobIds)
-
-
-
Field Detail
-
acquiredJobsByEngine
protected Map<String,AcquiredJobs> acquiredJobsByEngine
-
acquisitionException
protected Exception acquisitionException
-
acquisitionTime
protected long acquisitionTime
-
isJobAdded
protected boolean isJobAdded
-
-
Method Detail
-
submitAcquiredJobs
public void submitAcquiredJobs(String engineName, AcquiredJobs acquiredJobs)
-
submitAdditionalJobBatch
public void submitAdditionalJobBatch(String engineName, List<String> jobIds)
-
reset
public void reset()
-
areAllEnginesIdle
public boolean areAllEnginesIdle()
- Returns:
- true, if for all engines there were less jobs acquired than requested
-
hasJobAcquisitionLockFailureOccurred
public boolean hasJobAcquisitionLockFailureOccurred()
true if at least one job could not be locked, regardless of engine
-
setAcquisitionTime
public void setAcquisitionTime(long acquisitionTime)
-
getAcquisitionTime
public long getAcquisitionTime()
-
getAcquiredJobsByEngine
public Map<String,AcquiredJobs> getAcquiredJobsByEngine()
Jobs that were acquired in the current acquisition cycle.- Returns:
-
getRejectedJobsByEngine
public Map<String,List<List<String>>> getRejectedJobsByEngine()
Jobs that were rejected from execution in the acquisition cycle due to lacking execution resources. With an execution thread pool, these jobs could not be submitted due to saturation of the underlying job queue.
-
getAdditionalJobsByEngine
public Map<String,List<List<String>>> getAdditionalJobsByEngine()
Jobs that have been acquired in previous cycles and are supposed to be re-submitted for execution
-
setAcquisitionException
public void setAcquisitionException(Exception e)
-
getAcquisitionException
public Exception getAcquisitionException()
-
setJobAdded
public void setJobAdded(boolean isJobAdded)
-
isJobAdded
public boolean isJobAdded()
-
-