Hello,
Here is a test case that fails on a SimpleMerge node.
The schema definition is the following, please note the two branch loops (i put
actions in between to trace the execution):
--------------
<?xml version="1.0" encoding="UTF-8"?>
<workflow name="test" version="1">
<node id="1" type="Start">
<outNode id="3"/>
</node>
<node id="2" type="End"/>
<node id="3" type="Action" serviceObjectClass="MyServiceObject">
<arguments>
<string>INIT</string>
</arguments>
<outNode id="4"/>
</node>
<node id="4" type="SimpleMerge">
<outNode id="5"/>
</node>
<node id="5" type="Action" serviceObjectClass="MyServiceObject">
<arguments>
<string>ACTION 1</string>
</arguments>
<outNode id="6"/>
</node>
<node id="6" type="SimpleMerge">
<outNode id="7"/>
</node>
<node id="7" type="Action" serviceObjectClass="MyServiceObject">
<arguments>
<string>ACTION 2</string>
</arguments>
<outNode id="8"/>
</node>
<node id="8" type="Input">
<variable name="choice2">
<condition type="IsBool"/>
</variable>
<outNode id="9"/>
</node>
<node id="9" type="ExclusiveChoice">
<condition type="Variable" name="choice2">
<condition type="IsTrue"/>
<outNode id="10"/>
</condition>
<condition type="Variable" name="choice2">
<condition type="IsFalse"/>
<outNode id="4"/>
</condition>
</node>
<node id="10" type="Action" serviceObjectClass="MyServiceObject">
<arguments>
<string>ACTION 3</string>
</arguments>
<outNode id="11"/>
</node>
<node id="11" type="Input">
<variable name="choice3">
<condition type="IsBool"/>
</variable>
<outNode id="12"/>
</node>
<node id="12" type="ExclusiveChoice">
<condition type="Variable" name="choice3">
<condition type="IsFalse"/>
<outNode id="6"/>
</condition>
<condition type="Variable" name="choice3">
<condition type="IsTrue"/>
<outNode id="13"/>
</condition>
</node>
<node id="13" type="Action" serviceObjectClass="MyServiceObject">
<arguments>
<string>END</string>
</arguments>
<outNode id="2"/>
</node>
</workflow>
------------------
The MyServiceObject class only echoes the parameter String (as in the tutorial
example).
The execution is basic as follows (db stuff omitted):
$execution = new ezcWorkflowDatabaseExecution( $db );
$execution->workflow = $workflow;
$id = $execution->start();
$execution->resume(array('choice2'=>true));
$execution->resume(array('choice3'=>true));
I am not even trying to loop here (not relevant).
The execution outputs is the following:
message: INIT
message: ACTION 1
then it throws an exception:
Dec 15 14:15:30 PHP [alert] There is no thread with id #0
You can see the graphviz output of the stuck node and the whole schema in
attachment.
If i do just ONE loop in the schema (so i remove the 2nd merge node and 3rd
XOR) it works fine (no error, looping ok). Whenever i add the 2nd loop it
throws that error.
Maybe i am not using the proper nodes (simplemerge) ? I am stuck on this error.
Best regards,
Guillaume
failmerge.dot
Description: failmerge.dot
-- Components mailing list [email protected] http://lists.ez.no/mailman/listinfo/components
