<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2900.3314" name=GENERATOR></HEAD>
<BODY text=#000000 bgColor=#ffffff>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2>All very interesting.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2>Sadly, without spending time&nbsp;I don't have,&nbsp;this 
is beyond my level of&nbsp;understanding.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2>Sometimes you have to be honest and admit you're out of 
your depth, so I'll leave this with the experts...</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2>Relative to this observer you're moving at one heck of a 
pace!</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2>Thanks for the reply though.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=730425110-04082008><FONT face=Arial 
color=#0000ff size=2>Mike</FONT></SPAN><SPAN class=730425110-04082008><FONT 
face=Arial color=#0000ff size=2>&nbsp;</FONT></SPAN></DIV><BR>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
  <HR tabIndex=-1>
  <FONT face=Tahoma size=2><B>From:</B> rules-dev-bounces@lists.jboss.org 
  [mailto:rules-dev-bounces@lists.jboss.org] <B>On Behalf Of </B>Mark 
  Proctor<BR><B>Sent:</B> 01 August 2008 18:28<BR><B>To:</B> Rules Dev 
  List<BR><B>Subject:</B> [rules-dev] [Fwd: Re: [rules-users] determinism with 
  rulebasepartitioning]<BR></FONT><BR></DIV>
  <DIV></DIV>Forwarding the email to the dev mailing list, I meant the 
  conversation to be on this list anyway - sorry.<BR><BR>mark<BR><BR>-------- 
  Original Message --------<BR><BR>
  <DIV dir=ltr><BR>&nbsp;&nbsp;&nbsp; I think that even with rulebase 
  partitions, we should continue to support current execution mode. So, we 
  should keep a rulebase configuration that basically allow the user to defines: 
  either single-thread (as it is today) or multi-thread (as we are trying to 
  achieve) execution.<BR><BR>&nbsp;&nbsp;&nbsp; Having that in mind, in the 
  multi-thread mode:<BR><BR>(A) What does "parallel evaluation of a rulebase" 
  mean? Is it designed<BR>to optimise, for example, two threads processing a 
  stateless and<BR>stateful session?<BR>&nbsp;&nbsp; Means that rules that do 
  not share nodes, being independent of each other (from an evaluation 
  perspective), will be evaluated in parallel. This is very common scenario and 
  a desidered feature in CEP engines.<BR><BR>(B) Are there only two partitions, 
  both of which are invisible to the<BR>user? Is there any value in allowing 
  user-defined partitions?<BR>&nbsp;&nbsp;&nbsp; There will be as many 
  partitions as the compiler can create for the given set of rules. Rules that 
  share more nodes, are more difficult to partition, while rules that are 
  independent from an LHS point of view, are easier to parallelize. In my 
  opinion, the only thing that may be helpful to expose and allow the user to 
  control is the maximum size of the thread pool that is used to propagate 
  facts. Even that I'm not sure is so helpful, because it is complex to fine 
  tune such things, since the partitioning is completely dependent on the rules 
  added to the rulebase.<BR><BR>(C) Does the partition used depend upon what 
  type of session is used<BR>(i.e. stateless always uses the partition without 
  an agenda whereas<BR>stateful always uses the partition with an 
  agenda)?<BR>&nbsp;&nbsp;&nbsp; The partitioning of the rulebase is dependent 
  upon the rules in the rulebase and nothing more. But that is different from 
  the agenda. The agenda issue is much more complex, because even with 
  partitions we can keep a single deterministic agenda (as long as it is not in 
  active mode - runUntilHalt). Now, if the agenda is in active mode, or if we 
  have multiple agendas (1 per partition, for instance), then the engine 
  behavior becomes indeterministic. This is a common scenario in CEP systems 
  that have multiple different "queries" running over the same set of streams, 
  trying to detect and act upon them as soon as they are detected, and event 
  streams are indeterministic by their own nature. In common rules engines 
  scenarios, I'm not sure we can run in this indeterministic mode.<BR><BR>(D) 
  Can a rule sometimes be deterministic and sometimes not (i.e.<BR>depends upon 
  the type of session)?<BR>&nbsp;&nbsp;&nbsp; It will always depend on the set 
  of rules (the rulebase), not the type of session. One rule is always 
  deterministic when considered in isolation, but two or more rules may or may 
  not be deterministic in relation to each other. Just remember Eisten's 
  Relativity Theory... ;)<BR><BR>&nbsp;&nbsp; []s<BR>&nbsp;&nbsp; Edson<BR><BR>
  <DIV class=gmail_quote>2008/8/1 Anstis, Michael (M.) <SPAN dir=ltr>&lt;<A 
  href="mailto:manstis1@ford.com" 
  moz-do-not-send="true">manstis1@ford.com</A>&gt;</SPAN><BR>
  <BLOCKQUOTE class=gmail_quote 
  style="PADDING-LEFT: 1ex; MARGIN: 0pt 0pt 0pt 0.8ex; BORDER-LEFT: rgb(204,204,204) 1px solid">Hi 
    Mark,<BR><BR>A few questions:-<BR><BR>(A) What does "parallel evaluation of 
    a rulebase" mean? Is it designed<BR>to optimise, for example, two threads 
    processing a stateless and<BR>stateful session?<BR><BR>(B) Are there only 
    two partitions, both of which are invisible to the<BR>user? Is there any 
    value in allowing user-defined partitions?<BR><BR>(C) Does the partition 
    used depend upon what type of session is used<BR>(i.e. stateless always uses 
    the partition without an agenda whereas<BR>stateful always uses the 
    partition with an agenda)?<BR><BR>(D) Can a rule sometimes be deterministic 
    and sometimes not (i.e.<BR>depends upon the type of 
    session)?<BR><BR>Cheers,<BR><BR>Mike<BR>
    <DIV>
    <DIV class=Wj3C7c><BR>-----Original Message-----<BR>From: <A 
    href="mailto:rules-users-bounces@lists.jboss.org" 
    moz-do-not-send="true">rules-users-bounces@lists.jboss.org</A><BR>[mailto:<A 
    href="mailto:rules-users-bounces@lists.jboss.org" 
    moz-do-not-send="true">rules-users-bounces@lists.jboss.org</A>] On Behalf Of 
    Mark Proctor<BR>Sent: 01 August 2008 07:05<BR>To: Rules Users 
    List<BR>Subject: [rules-users] determinism with rulebase 
    partitioning<BR><BR>We have rulebase partitioning almost working, this 
    allows parallel<BR>evaluation of a rulebase. For stateless lessions with no 
    agenda this<BR>will allow for much faster executions, where you don't care 
    about<BR>deterministic execution. However for deterministic execution its 
    more<BR>complicated. The current plan is to have an agenda per parition, 
    which<BR>means that we no longer have rulebase wide deterministic 
    execution<BR>order, only with the partition itself. The user is unlikely to 
    be aware<BR>of the created partitions, so won't be aware of the 
    unditermistic<BR>behavour of their rulebase. Anyone have any input on 
    mechanisms users<BR>can do to help the rulebase know what needs to be 
    executed<BR>deterministically and what 
    doesn't?<BR><BR>Mark<BR>_______________________________________________<BR>rules-users 
    mailing list<BR><A href="mailto:rules-users@lists.jboss.org" 
    moz-do-not-send="true">rules-users@lists.jboss.org</A><BR><A 
    href="https://lists.jboss.org/mailman/listinfo/rules-users" target=_blank 
    moz-do-not-send="true">https://lists.jboss.org/mailman/listinfo/rules-users</A><BR><BR>_______________________________________________<BR>rules-users 
    mailing list<BR><A href="mailto:rules-users@lists.jboss.org" 
    moz-do-not-send="true">rules-users@lists.jboss.org</A><BR><A 
    href="https://lists.jboss.org/mailman/listinfo/rules-users" target=_blank 
    moz-do-not-send="true">https://lists.jboss.org/mailman/listinfo/rules-users</A><BR></DIV></DIV></BLOCKQUOTE></DIV><BR><BR 
  clear=all><BR>-- <BR>Edson Tirelli<BR>JBoss Drools Core Development<BR>JBoss, 
  a division of Red Hat @ <A href="http://www.jboss.com" 
  moz-do-not-send="true">www.jboss.com</A><BR></DIV></BLOCKQUOTE></BODY></HTML>