Class DefaultWorkflowLauncher
java.lang.Object
com.broadleafcommerce.workflow.service.DefaultWorkflowLauncher
- All Implemented Interfaces:
WorkflowLauncher
,org.springframework.context.Lifecycle
,org.springframework.context.Phased
,org.springframework.context.SmartLifecycle
See
WorkflowLauncher
-
Field Summary
Fields inherited from interface org.springframework.context.SmartLifecycle
DEFAULT_PHASE
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultWorkflowLauncher
(ExecutionProperties executionProperties, WorkflowRunner runner, org.springframework.context.ApplicationEventPublisher applicationEventPublisher, WorkflowRepository<com.broadleafcommerce.data.tracking.core.Trackable> workflowRepository, com.broadleafcommerce.data.tracking.core.BasicAuditUtility auditUtility, WorkflowService<Workflow> workflowService, com.broadleafcommerce.orchestration.spring.SimpleWorkflowFactory factory) -
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
boolean
spawn
(Informational workFlow) Launch a new workflow into an async thread pool for executionvoid
start()
void
stop()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.springframework.context.SmartLifecycle
getPhase, stop
-
Constructor Details
-
DefaultWorkflowLauncher
public DefaultWorkflowLauncher(ExecutionProperties executionProperties, WorkflowRunner runner, org.springframework.context.ApplicationEventPublisher applicationEventPublisher, WorkflowRepository<com.broadleafcommerce.data.tracking.core.Trackable> workflowRepository, com.broadleafcommerce.data.tracking.core.BasicAuditUtility auditUtility, WorkflowService<Workflow> workflowService, com.broadleafcommerce.orchestration.spring.SimpleWorkflowFactory factory)
-
-
Method Details
-
isRunning
public boolean isRunning()- Specified by:
isRunning
in interfaceorg.springframework.context.Lifecycle
-
isAutoStartup
public boolean isAutoStartup()- Specified by:
isAutoStartup
in interfaceorg.springframework.context.SmartLifecycle
-
start
public void start()- Specified by:
start
in interfaceorg.springframework.context.Lifecycle
-
stop
public void stop()- Specified by:
stop
in interfaceorg.springframework.context.Lifecycle
-
spawn
Description copied from interface:WorkflowLauncher
Launch a new workflow into an async thread pool for execution- Specified by:
spawn
in interfaceWorkflowLauncher
- Parameters:
workFlow
- Information about the workflow to execute- Returns:
- Whether a thread was able to handle the request before a timeout occurred
-