public abstract class BaseWorkflowStrategy extends java.lang.Object implements WorkflowStrategy
NODE_FIRST, PARALLEL, STEP_FIRST
Constructor and Description |
---|
BaseWorkflowStrategy(Framework framework) |
Modifier and Type | Method and Description |
---|---|
protected StepExecutionContext |
addNodeStepFailureContextData(StepExecutionResult dispatcherStepResult,
StepExecutionContext handlerExecContext)
Add any node-specific step failure information to the node-specific data contexts
|
protected StepExecutionContext |
addStepFailureContextData(StepExecutionResult stepResult,
StepExecutionContext handlerExecContext)
Add step result failure information to the data context
|
protected java.util.Map<java.lang.String,java.util.Collection<StepExecutionResult>> |
convertFailures(java.util.Map<java.lang.Integer,StepExecutionResult> failedMap)
Convert map of step execution results keyed by step number, to a collection of step execution results
keyed by node name
|
protected java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> |
createPrintableDataContext(java.lang.String optionKey,
java.lang.String secureOptionKey,
java.lang.String secureOptionValue,
java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> dataContext)
Creates a copy of the given data context with the secure option values obfuscated.
|
protected StepExecutionResult |
executeWFItem(StepExecutionContext executionContext,
java.util.Map<java.lang.Integer,StepExecutionResult> failedMap,
int c,
StepExecutionItem cmd)
Execute a workflow item, returns true if the item succeeds.
|
WorkflowExecutionResult |
executeWorkflow(StepExecutionContext executionContext,
WorkflowExecutionItem item) |
abstract WorkflowExecutionResult |
executeWorkflowImpl(StepExecutionContext executionContext,
WorkflowExecutionItem item) |
protected WorkflowStatusResult |
executeWorkflowItemsForNodeSet(StepExecutionContext executionContext,
java.util.Map<java.lang.Integer,StepExecutionResult> failedMap,
java.util.List<StepExecutionResult> resultList,
java.util.List<StepExecutionItem> iWorkflowCmdItems,
boolean keepgoing)
Execute the sequence of ExecutionItems within the context, and with the given keepgoing value
|
protected WorkflowStatusResult |
executeWorkflowItemsForNodeSet(StepExecutionContext executionContext,
java.util.Map<java.lang.Integer,StepExecutionResult> failedMap,
java.util.List<StepExecutionResult> resultList,
java.util.List<StepExecutionItem> iWorkflowCmdItems,
boolean keepgoing,
int beginStepIndex)
Execute the sequence of ExecutionItems within the context, and with the given keepgoing value
|
protected WorkflowExecutionListener |
getWorkflowListener(ExecutionContext executionContext) |
protected static NodeStepResult |
nodeStepResultFromNodeStepException(INodeEntry node,
NodeStepException nodeStepException) |
protected StepExecutionContext |
replaceFailedNodesListenerInContext(StepExecutionContext executionContext,
FailedNodesListener captureFailedNodesListener) |
public BaseWorkflowStrategy(Framework framework)
public final WorkflowExecutionResult executeWorkflow(StepExecutionContext executionContext, WorkflowExecutionItem item)
executeWorkflow
in interface WorkflowExecutor
protected WorkflowExecutionListener getWorkflowListener(ExecutionContext executionContext)
public abstract WorkflowExecutionResult executeWorkflowImpl(StepExecutionContext executionContext, WorkflowExecutionItem item)
protected StepExecutionResult executeWFItem(StepExecutionContext executionContext, java.util.Map<java.lang.Integer,StepExecutionResult> failedMap, int c, StepExecutionItem cmd)
executionContext
- contextfailedMap
- List to add any messages if the item failsc
- index of the WF itemcmd
- WF item descriptorprotected WorkflowStatusResult executeWorkflowItemsForNodeSet(StepExecutionContext executionContext, java.util.Map<java.lang.Integer,StepExecutionResult> failedMap, java.util.List<StepExecutionResult> resultList, java.util.List<StepExecutionItem> iWorkflowCmdItems, boolean keepgoing)
executionContext
- contextfailedMap
- failuresresultList
- resultsiWorkflowCmdItems
- list of stepskeepgoing
- true to keepgoing on step failureprotected WorkflowStatusResult executeWorkflowItemsForNodeSet(StepExecutionContext executionContext, java.util.Map<java.lang.Integer,StepExecutionResult> failedMap, java.util.List<StepExecutionResult> resultList, java.util.List<StepExecutionItem> iWorkflowCmdItems, boolean keepgoing, int beginStepIndex)
executionContext
- contextfailedMap
- failuresresultList
- resultsiWorkflowCmdItems
- list of stepskeepgoing
- true to keepgoing on step failurebeginStepIndex
- beginning step indexprotected StepExecutionContext addStepFailureContextData(StepExecutionResult stepResult, StepExecutionContext handlerExecContext)
stepResult
- resulthandlerExecContext
- contextprotected StepExecutionContext addNodeStepFailureContextData(StepExecutionResult dispatcherStepResult, StepExecutionContext handlerExecContext)
dispatcherStepResult
- resulthandlerExecContext
- contextprotected StepExecutionContext replaceFailedNodesListenerInContext(StepExecutionContext executionContext, FailedNodesListener captureFailedNodesListener)
protected java.util.Map<java.lang.String,java.util.Collection<StepExecutionResult>> convertFailures(java.util.Map<java.lang.Integer,StepExecutionResult> failedMap)
failedMap
- failuresprotected static NodeStepResult nodeStepResultFromNodeStepException(INodeEntry node, NodeStepException nodeStepException)
node
- nodenodeStepException
- exceptionprotected java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> createPrintableDataContext(java.lang.String optionKey, java.lang.String secureOptionKey, java.lang.String secureOptionValue, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> dataContext)
optionKey
- keysecureOptionKey
- secure keysecureOptionValue
- secure valuedataContext
- data