public class Spawning extends java.lang.Object implements XMLable, java.io.Serializable
EXEC_TYPE_SEQUENCE
but they can be configured to execute
in EXEC_TYPE_PARALLEL
.
When the nodes are executed in parallel, how the flow if the process should
continue also needs to be configured. There are four patterns available,
which specify the behavior of the process flow then the nodes are executed
in parallel. This class defines the spawning properties for a node.Instances
,
Serialized FormModifier and Type | Field and Description |
---|---|
static int |
EXEC_TYPE_PARALLEL
Spawned nodes will be executed in parallel.
|
static int |
EXEC_TYPE_SEQUENTIAL
Spawned nodes will be executed in sequence.
|
static int |
PARALL_FLOW_COMPLEX_NODE
The next node in the process is executed, only when the complex node
expression evaluates to true.
|
static int |
PARALL_FLOW_RUN_ALL
When the spawned node are executing in parallel, the next node will be
executed for all the spawned instances.
|
static int |
PARALL_FLOW_RUN_ONCE
When the spawned nodes are executing in parallel, the next node in the
process will be executed only once (for the spawned node instance that
executes first).
|
static int |
PARALL_FLOW_WAIT_FOR_ALL
When the spawned nodes are executing in parallel, the next node in the
process is executed only when all the spawned instances have finished
execution.
|
DEFAULT_BUFFER_SIZE
Constructor and Description |
---|
Spawning() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getComplexNodeMergeExpression()
Returns the expression that needs to be true when multiple instances of
nodes are running in parallel and parallelMergeType is set to
PARALL_FLOW_COMPLEX_NODE |
Instances |
getInstances()
Returns the
Instances configuration. |
java.lang.Integer |
getParallelMergeType()
Returns the merge property when the node instances are running in
parallel.
|
boolean |
isAllowMNIBatching()
Returns true if more than
ServerProcessCommonConfiguration#getMaxNodeInstances nodes can be spawned in batches. |
boolean |
isParallelExecution()
Returns true if the nodes will be executed in parallel.
|
void |
setAllowMNIBatching(boolean allowMNIBatching)
Sets if the MNI batching of more than
ServerProcessCommonConfiguration#getMaxNodeInstances nodes is allowed |
void |
setComplexNodeMergeExpression(java.lang.String nmMergeExpression_)
Sets the expression that needs to be true when multiple instances of nodes
are running in parallel and parallelMergeType is set to
PARALL_FLOW_COMPLEX_NODE |
void |
setInstances(Instances instances_)
Sets the
Instances configuration. |
void |
setParallelExecution(boolean executionType_)
Sets how the spawned nodes are executed.
|
void |
setParallelMergeType(java.lang.Integer parallelMergeType_)
Sets the merge property when the node instances are running in parallel.
|
java.lang.String |
toXML()
Spawn instances equal to the difference in the number of elements in
Process Variable array and the number of instances created in the previous
execution.
|
void |
toXML(java.lang.StringBuilder buffer_)
Appends an XML representation of this object (including all
child objects) to the given buffer.
|
public static final int EXEC_TYPE_SEQUENTIAL
public static final int EXEC_TYPE_PARALLEL
public static final int PARALL_FLOW_RUN_ALL
public static final int PARALL_FLOW_RUN_ONCE
public static final int PARALL_FLOW_WAIT_FOR_ALL
public static final int PARALL_FLOW_COMPLEX_NODE
public java.lang.String toXML()
public void toXML(java.lang.StringBuilder buffer_)
XMLable
public boolean isParallelExecution()
EXEC_TYPE_PARALLEL
,
EXEC_TYPE_SEQUENTIAL
public void setParallelExecution(boolean executionType_)
executionType_
- true if the nodes are set to execute in parallelEXEC_TYPE_PARALLEL
,
EXEC_TYPE_SEQUENTIAL
public boolean isAllowMNIBatching()
ServerProcessCommonConfiguration#getMaxNodeInstances
nodes can be spawned in batches.public void setAllowMNIBatching(boolean allowMNIBatching)
ServerProcessCommonConfiguration#getMaxNodeInstances
nodes is allowed_allowMNIBatching
- true if the nodes are set to execute in parallelpublic Instances getInstances()
Instances
configuration.public void setInstances(Instances instances_)
Instances
configuration.instances_
- instances objectpublic java.lang.String getComplexNodeMergeExpression()
PARALL_FLOW_COMPLEX_NODE
public void setComplexNodeMergeExpression(java.lang.String nmMergeExpression_)
PARALL_FLOW_COMPLEX_NODE
nmMergeExpression_
- String representing the expressionpublic java.lang.Integer getParallelMergeType()
PARALL_FLOW_RUN_ONCE
,
PARALL_FLOW_COMPLEX_NODE
,
PARALL_FLOW_RUN_ALL
,
PARALL_FLOW_WAIT_FOR_ALL
public void setParallelMergeType(java.lang.Integer parallelMergeType_)
parallelMergeType_
- integer representing parallel mergegetParallelMergeType()
Copyright © 2003-2024 Appian Corporation. All Rights Reserved.