Class DefaultDistributedProcessService
java.lang.Object
de.hybris.platform.processing.distributed.defaultimpl.DefaultDistributedProcessService
- All Implemented Interfaces:
DistributedProcessService
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultDistributedProcessService(ModelService modelService, FlexibleSearchService flexibleSearchService, Controller controller) -
Method Summary
Modifier and TypeMethodDescription<T extends DistributedProcessModel>
Tcreate(ProcessCreationData creationData) Creates process based onProcessCreationDatagetCurrentStatus(String processCode) Get current status of distributed process<T extends DistributedProcessModel>
TrequestToStop(String processCode) Mark process with given code as requested to stop.<T extends DistributedProcessModel>
TStarts process with given code<T extends DistributedProcessModel>
TWait for process to be finished.
-
Constructor Details
-
DefaultDistributedProcessService
public DefaultDistributedProcessService(ModelService modelService, FlexibleSearchService flexibleSearchService, Controller controller)
-
-
Method Details
-
create
Description copied from interface:DistributedProcessServiceCreates process based onProcessCreationData- Specified by:
createin interfaceDistributedProcessService- Parameters:
creationData- process creation data- Returns:
- created process
-
start
Description copied from interface:DistributedProcessServiceStarts process with given code- Specified by:
startin interfaceDistributedProcessService- Parameters:
processCode- code of process to be started- Returns:
- started process
-
requestToStop
Description copied from interface:DistributedProcessServiceMark process with given code as requested to stop. It doesn't stop the process.- Specified by:
requestToStopin interfaceDistributedProcessService- Parameters:
processCode- code of process to be stopped- Returns:
- process
-
wait
public <T extends DistributedProcessModel> T wait(String processCode, long maxWaitTimeInSeconds) throws InterruptedException Description copied from interface:DistributedProcessServiceWait for process to be finished. Process is considered as finish if it's in stateDistributedProcessState.SUCCEEDED,DistributedProcessState.STOPPEDorDistributedProcessState.FAILED. It wait's for a given time and if it returns caller need to check whether the process is really finished.- Specified by:
waitin interfaceDistributedProcessService- Parameters:
processCode- code of process to be waited formaxWaitTimeInSeconds- time in seconds- Returns:
- process
- Throws:
InterruptedException
-
getCurrentStatus
Description copied from interface:DistributedProcessServiceGet current status of distributed process- Specified by:
getCurrentStatusin interfaceDistributedProcessService- Parameters:
processCode- code of process- Returns:
- current status
-