Class ExecutorServiceBean
- java.lang.Object
 - 
- org.camunda.bpm.container.impl.ejb.ExecutorServiceBean
 
 
- 
- All Implemented Interfaces:
 ExecutorService
public class ExecutorServiceBean extends java.lang.Object implements ExecutorService
Bean exposing the JCA implementation of theExecutorServiceas Stateless Bean.- Author:
 - Daniel Meyer
 
 
- 
- 
Field Summary
Fields Modifier and Type Field Description protected JcaExecutorServiceConnectionexecutorConnectionprotected JcaExecutorServiceConnectionFactoryexecutorConnectionFactory 
- 
Constructor Summary
Constructors Constructor Description ExecutorServiceBean() 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidcloseConnection()java.lang.RunnablegetExecuteJobsRunnable(java.util.List<java.lang.String> jobIds, ProcessEngineImpl processEngine)Returns a runnable to be used for executing Jobs.protected voidopenConnection()booleanschedule(java.lang.Runnable runnable, boolean isLongRunning)Passes aRunnableto the runtime container for execution. 
 - 
 
- 
- 
Field Detail
- 
executorConnectionFactory
protected JcaExecutorServiceConnectionFactory executorConnectionFactory
 
- 
executorConnection
protected JcaExecutorServiceConnection executorConnection
 
 - 
 
- 
Method Detail
- 
openConnection
@PostConstruct protected void openConnection()
 
- 
closeConnection
@PreDestroy protected void closeConnection()
 
- 
schedule
public boolean schedule(java.lang.Runnable runnable, boolean isLongRunning)Description copied from interface:ExecutorServicePasses a
Runnableto the runtime container for execution. Some runtime containers (like a Java EE container offer container provided infrastructure for executing background work (such as a JCA WorkManager). This method allows the process engine to take advantage of container infrastructure for doing background work.- Specified by:
 schedulein interfaceExecutorService- Parameters:
 runnable- theRunnableto be executed.isLongRunning- indicates whether the runnable is a daemon.- Returns:
 - true if the runnable could be successfully scheduled for execution. 'false' otherwise.
 
 
- 
getExecuteJobsRunnable
public java.lang.Runnable getExecuteJobsRunnable(java.util.List<java.lang.String> jobIds, ProcessEngineImpl processEngine)Description copied from interface:ExecutorServiceReturns a runnable to be used for executing Jobs.
- Specified by:
 getExecuteJobsRunnablein interfaceExecutorService- Returns:
 
 
 - 
 
 -