public class ProcessDataAccessImpl extends Object implements ProcessDataAccess
Modifier and Type | Method and Description |
---|---|
void |
addToWorkflowList(ProcessWorkflow processWorkflow)
Add process to Workflow
Only use on application starting to load persisted workflow (state are PAUSED or FAILED only) |
void |
clearWorkflow() |
List<ProcessWorkflow> |
findAllProcessWorkflow(Integer tenantId)
Retrieves All the workflow process for monitoring purpose The final business scope of this feature is likely to
be redefined, to match the future need
|
ProcessWorkflow |
findOneProcessWorkflow(String processId,
Integer tenantId)
Gets Process Workflow by ID
|
static ProcessDataAccessImpl |
getInstance()
Get the Process Monitoring instance
|
Map<Integer,Map<String,ProcessWorkflow>> |
getWorkFlowList()
getter of WorkflowList
|
ProcessWorkflow |
initProcessWorkflow(WorkFlow workflow,
String containerName,
LogbookTypeProcess logbookTypeProcess,
Integer tenantId,
String contextId)
Allows a process to be initialized
|
void |
updateStep(String operationId,
String uniqueStepId,
long elementToProcessOrProcessed,
boolean elementProcessed,
Integer tenantId)
Update a step in a workflow, knowing its unique id
|
public static ProcessDataAccessImpl getInstance()
public ProcessWorkflow initProcessWorkflow(WorkFlow workflow, String containerName, LogbookTypeProcess logbookTypeProcess, Integer tenantId, String contextId)
ProcessDataAccess
initProcessWorkflow
in interface ProcessDataAccess
workflow
- the workflow to initcontainerName
- : null not allowed , the name of the container to be processedlogbookTypeProcess
- LogbookTypeProcess
tenantId
- the working tenantcontextId
- the context IDLogbookTypeProcess
public void updateStep(String operationId, String uniqueStepId, long elementToProcessOrProcessed, boolean elementProcessed, Integer tenantId)
ProcessDataAccess
updateStep
in interface ProcessDataAccess
operationId
- the id of the process to be updateduniqueStepId
- the unique Id of the stepelementToProcessOrProcessed
- the number of element to be processedelementProcessed
- if a new element has been processedtenantId
- the working tenantpublic ProcessWorkflow findOneProcessWorkflow(String processId, Integer tenantId) throws WorkflowNotFoundException
ProcessDataAccess
findOneProcessWorkflow
in interface ProcessDataAccess
processId
- the process idtenantId
- the working tenantProcessWorkflow
WorkflowNotFoundException
- thrown when process workflow not foundpublic void clearWorkflow()
public List<ProcessWorkflow> findAllProcessWorkflow(Integer tenantId)
ProcessDataAccess
findAllProcessWorkflow
in interface ProcessDataAccess
tenantId
- the working tenantpublic void addToWorkflowList(ProcessWorkflow processWorkflow)
ProcessDataAccess
addToWorkflowList
in interface ProcessDataAccess
processWorkflow
- the loaded persisted process to addpublic Map<Integer,Map<String,ProcessWorkflow>> getWorkFlowList()
ProcessDataAccess
getWorkFlowList
in interface ProcessDataAccess
Copyright © 2018 Vitam. All rights reserved.