<div> </div>
<div>Thank U again Kris.</div>
<div> </div>
<div>I Think I misunderstood How a ruleflow works... for "parallelism" I meant two rules that are activated in the same time</div>
<div>but I know that it is a non-sense cause the ruleflow itself remove any ambiguity concerning the agenda.</div>
<div> </div>
<div>Sorry about that!</div>
<div> </div>
<div>Hopefully next time I will post something a bit more interesting.... :( ;-)</div>
<div> </div>
<div>Thank You again! </div>
<div> </div>
<div>massi<br><br></div>
<div class="gmail_quote">On Nov 23, 2007 12:22 AM, Kris Verlaenen <<a href="mailto:kris.verlaenen@cs.kuleuven.be">kris.verlaenen@cs.kuleuven.be</a>> wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<div bgcolor="#ffffff">
<div>Massi,</div>
<div> </div>
<div><font face="Arial" size="2">Why do you want to use a ruleflow? </font><font face="Arial" size="2">If you simply remove the ruleflow-group statements from your rule definitions, you will get your expected behaviour, as rule_ab will execute first, updating your user fact, which will then trigger rule_ba to execute, updating the user fact again, which will trigger rule_ba again, etc.
</font></div>
<div><font face="Arial" size="2"></font> </div>
<div><font face="Arial" size="2">I'm not sure where you see any parallelism here, as it is always the first rule, then the second, then the first one again, etc.</font></div>
<div><font face="Arial" size="2"></font> </div>
<div><font face="Arial" size="2">But if you really want to know, you can create a loop in a ruleflow by putting whatever you would like to see repeated in between an XOR-join in front and an XOR-split at the end, and linking one of the outgoing connections of the XOR-split back to the first join :)
</font></div>
<div><font face="Arial" size="2"></font> </div>
<div><font face="Arial" size="2">Kris</font></div>
<div><font face="Arial" size="2"></font> </div>
<blockquote style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<div>
<div></div>
<div class="Wj3C7c">
<div style="FONT: 10pt arial">----- Original Message ----- </div>
<div style="BACKGROUND: #e4e4e4; FONT: 10pt arial"><b>From:</b> <a title="mmquelo@gmail.com" href="mailto:mmquelo@gmail.com" target="_blank">mmquelo massi</a> </div>
<div style="FONT: 10pt arial"><b>To:</b> <a title="rules-users@lists.jboss.org" href="mailto:rules-users@lists.jboss.org" target="_blank">Rules Users List</a> </div>
<div style="FONT: 10pt arial"><b>Sent:</b> Thursday, November 22, 2007 5:15 PM</div>
<div style="FONT: 10pt arial"><b>Subject:</b> [rules-users] How to make a "Loop-Ruleflow"????</div>
<div><br></div>
<div></div>
<div>Hi everybody. </div>
<div> </div>
<div></div>
<div>I am trying to make a ruleflow that, once processed, causes the rule engine to infinitely loop. </div>
<div>I have got a <em>User</em> Object in my object model. It has got a <em>getLogin()</em> and <em>setLogin(</em>) methods. </div>
<div> </div>
<div>The login field stands for the "User name", so it is a String. </div>
<div> </div>
<div>First I insert an Object in the WM, with login==A.</div>
<div> </div>
<div></div>
<div>Then I generate the following rule-flow-groups: </div>
<div> </div>
<div><em>rule "rule_ab" </em></div>
<div><em> ruleflow-group "ab" </em></div>
<div><em> when </em></div>
<div><em> u:User( login == "A" ) </em></div>
<div><em> then </em></div>
<div><em> u.setLogin("B"); </em></div>
<div><em> System.out.println("a - > b"); </em></div>
<div><em> update(u); </em></div>
<div><em>end </em></div>
<div><em></em> </div>
<div><em>rule "rule_ba" </em></div>
<div><em> ruleflow-group "ba" </em></div>
<div><em> when </em></div>
<div><em> u:User( login == "B" ) </em></div>
<div><em> then </em></div>
<div><em> u.setLogin("A"); </em></div>
<div><em> System.out.println("b - > a"); </em></div>
<div><em> update(u); </em></div>
<div><em>end </em></div>
<div> </div>
<div>I'd like to define a ruleflow that gives me in output something like this:</div>
<div> </div>
<div>
<div>a - > b</div>
<div>b - > a</div>
<div>a - > b</div>
<div>b - > a
<div>a - > b</div>
<div>b - > a</div>
<div>a - > b</div>
<div>b - > a
<div>a - > b</div>
<div>b - > a</div>
<div>a - > b</div>
<div>b - > a</div>
<div>.... looping...</div>
<div> </div>
<div>How can I do it?</div>
<div> </div>
<div>In other words I want those rules to be executed in parallel and I want to define</div>
<div>this "parallelism" using the ruleflow graph, Is It Possible???</div>
<div> </div>
<div>Thank You Again!</div>
<div> </div>
<div>Massi.</div>
<div> </div>
<div>P.S.</div>
<div> </div>
<div>Ah.... I solved that matter with the rule.package...</div></div></div></div></div></div>
<p>
<hr>
<p></p>_______________________________________________<br>rules-users mailing list<br><a href="mailto:rules-users@lists.jboss.org" target="_blank">rules-users@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">
https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
<p></p></p></blockquote></div><br>_______________________________________________<br>rules-users mailing list<br><a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">
https://lists.jboss.org/mailman/listinfo/rules-users</a><br><br></blockquote></div><br>