Class MscExecutorService
java.lang.Object
org.camunda.bpm.container.impl.jboss.service.MscExecutorService
- All Implemented Interfaces:
ExecutorService
,org.jboss.msc.Service
,org.jboss.msc.service.Service<MscExecutorService>
,org.jboss.msc.value.Value<MscExecutorService>
public class MscExecutorService
extends Object
implements org.jboss.msc.service.Service<MscExecutorService>, ExecutorService
-
Field Summary
Fields inherited from interface org.jboss.msc.service.Service
NULL
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetExecuteJobsRunnable
(List<String> jobIds, ProcessEngineImpl processEngine) Returns a runnable to be used for executing Jobs.org.jboss.msc.value.InjectedValue<org.jboss.as.threads.ManagedQueueExecutorService>
getValue()
boolean
Passes aRunnable
to the runtime container for execution.protected boolean
scheduleLongRunningWork
(Runnable runnable) protected boolean
scheduleShortRunningWork
(Runnable runnable) void
start
(org.jboss.msc.service.StartContext context) void
stop
(org.jboss.msc.service.StopContext context)
-
Constructor Details
-
MscExecutorService
public MscExecutorService()
-
-
Method Details
-
getValue
- Specified by:
getValue
in interfaceorg.jboss.msc.value.Value<MscExecutorService>
- Throws:
IllegalStateException
IllegalArgumentException
-
start
public void start(org.jboss.msc.service.StartContext context) throws org.jboss.msc.service.StartException - Specified by:
start
in interfaceorg.jboss.msc.Service
- Throws:
org.jboss.msc.service.StartException
-
stop
public void stop(org.jboss.msc.service.StopContext context) - Specified by:
stop
in interfaceorg.jboss.msc.Service
-
getExecuteJobsRunnable
Description copied from interface:ExecutorService
Returns a runnable to be used for executing Jobs.
- Specified by:
getExecuteJobsRunnable
in interfaceExecutorService
- Returns:
-
schedule
Description copied from interface:ExecutorService
Passes a
Runnable
to 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:
schedule
in interfaceExecutorService
- Parameters:
runnable
- theRunnable
to be executed.isLongRunning
- indicates whether the runnable is a daemon.- Returns:
- true if the runnable could be successfully scheduled for execution. 'false' otherwise.
-
scheduleShortRunningWork
-
scheduleLongRunningWork
-
getManagedQueueInjector
public org.jboss.msc.value.InjectedValue<org.jboss.as.threads.ManagedQueueExecutorService> getManagedQueueInjector()
-