org.camunda.bpm.engine.impl.cmd
Class AcquireJobsCmd

java.lang.Object
  extended by org.camunda.bpm.engine.impl.cmd.AcquireJobsCmd
All Implemented Interfaces:
OptimisticLockingListener, Command<AcquiredJobs>

public class AcquireJobsCmd
extends Object
implements Command<AcquiredJobs>, OptimisticLockingListener

Author:
Nick Burch, Daniel Meyer

Field Summary
protected  AcquiredJobs acquiredJobs
           
 
Constructor Summary
AcquireJobsCmd(JobExecutor jobExecutor)
           
 
Method Summary
 AcquiredJobs execute(CommandContext commandContext)
           
 void failedOperation(DbOperation operation)
          Signifies that an operation failed due to optimistic locking.
 Class<? extends DbEntity> getEntityType()
          The type of the entity for which this listener should be notified.
protected  void lockJob(JobEntity job, String lockOwner, int lockTimeInMillis)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

acquiredJobs

protected AcquiredJobs acquiredJobs
Constructor Detail

AcquireJobsCmd

public AcquireJobsCmd(JobExecutor jobExecutor)
Method Detail

execute

public AcquiredJobs execute(CommandContext commandContext)
Specified by:
execute in interface Command<AcquiredJobs>

lockJob

protected void lockJob(JobEntity job,
                       String lockOwner,
                       int lockTimeInMillis)

getEntityType

public Class<? extends DbEntity> getEntityType()
Description copied from interface: OptimisticLockingListener
The type of the entity for which this listener should be notified. If the implementation returns 'null', the listener is notified for all entity types.

Specified by:
getEntityType in interface OptimisticLockingListener
Returns:
the entity type for which the listener should be notified.

failedOperation

public void failedOperation(DbOperation operation)
Description copied from interface: OptimisticLockingListener
Signifies that an operation failed due to optimistic locking.

Specified by:
failedOperation in interface OptimisticLockingListener
Parameters:
operation - the failed operation.


Copyright © 2015 camunda services GmbH. All rights reserved.