<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
    <title></title>
  </head>
  <body bgcolor="#ffffff" text="#000000">
    <br>
    On 12/1/10 5:09 PM, Chris Selwyn wrote:
    <blockquote cite="mid:4CF6C7A4.4040307@selwyn-family.me.uk"
      type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      Having just looked in the Drools JIRA repository, I pretty sure
      that it is the same issue as was reported in <a
        moz-do-not-send="true"
        href="https://jira.jboss.org/browse/JBRULES-2140">JBRULES-2140</a>.<br>
      That entry has a repro.<br>
    </blockquote>
    thanks for finding<br>
    <blockquote cite="mid:4CF6C7A4.4040307@selwyn-family.me.uk"
      type="cite"> <br>
      I am interested as to what you mean by "right around the corner"?<br>
      <br>
    </blockquote>
    this month<br>
    <blockquote cite="mid:4CF6C7A4.4040307@selwyn-family.me.uk"
      type="cite"> Here is a repro anyway...<br>
      <br>
      &lt;QUOTE&gt;<br>
      package rulestest<br>
      global java.util.logging.Logger logger<br>
      <br>
      declare QuestionValidation<br>
      &nbsp;&nbsp;&nbsp; question: String<br>
      &nbsp;&nbsp;&nbsp; mandatory: Boolean<br>
      &nbsp;&nbsp;&nbsp; state: String<br>
      &nbsp;&nbsp;&nbsp; type: String<br>
      end<br>
      <br>
      function void testfunc() {<br>
      System.out.println("testfunc called");<br>
      <br>
      }<br>
      <br>
      rule 'init'<br>
      dialect "mvel"<br>
      when<br>
      &nbsp;&nbsp;&nbsp; eval(true)<br>
      then<br>
      &nbsp;&nbsp;&nbsp; QuestionValidation qv = new QuestionValidation();<br>
      &nbsp;&nbsp;&nbsp; qv.setState("ss");<br>
      &nbsp;&nbsp;&nbsp; qv.setQuestion("qq");<br>
      &nbsp;&nbsp;&nbsp; insert(qv);<br>
      &nbsp;&nbsp;&nbsp; logger.info("Hello world");<br>
      <br>
      end<br>
      <br>
      rule 'test'<br>
      dialect "mvel"<br>
      when<br>
      &nbsp;&nbsp;&nbsp; $qv: QuestionValidation()<br>
      then<br>
      &nbsp;&nbsp;&nbsp; logger.info("Found a qv " + $qv);<br>
      <br>
      end<br>
      &lt;/QUOTE&gt;<br>
      <br>
      If the testfunc is present then the "test" rule never fires. If it
      is not present then the "test" rule fires just fine.<br>
      <br>
      Chris<br>
      <br>
      On 01/12/2010 21:47, Tihomir Surdilovic wrote:
      <blockquote cite="mid:4CF6C274.1070707@redhat.com" type="cite">
        <meta content="text/html; charset=ISO-8859-1"
          http-equiv="Content-Type">
        Hi Chris, could you attach the repository export xml from your
        repo that I can use to reproduce the issue with? BRMS 5.1
        (supported bits) is right around the corner and I would be able
        to tell you if the issue still persists with the currently
        tested bits for 5.1.<br>
        <br>
        Thanks.<br>
        Tihomir<br>
        <br>
        On 12/1/10 4:29 PM, Chris Selwyn wrote:
        <blockquote cite="mid:4CF6BE2D.40700@selwyn-family.me.uk"
          type="cite">
          <meta content="text/html; charset=ISO-8859-1"
            http-equiv="Content-Type">
          Having spent all day on this one, I have finally got to the
          bottom of it.<br>
          <br>
          The problem is reproducible if I have <i>both</i> a
          declarative fact model <i>and</i> a function in my rules.<br>
          It doesn't matter whether the function is called or not...
          It's presence is enough to&nbsp; cause the problem.<br>
          <br>
          Any rule that is dependent on the existence of an instance of
          the declarative fact model where the instance is created in
          the RHS of another rule will not fire.<br>
          <br>
          I suspect that this is a bug that has been fixed in 5.1
          because I have been using this technique in Drools 5.1... It's
          only since downgrading to the (supported) JBoss Rules 5.0 that
          I have experienced the problem.<br>
          <br>
          Does anyone know if there is a fix in the 5.0 branch?<br>
          <br>
          If I create a "real" Java class and upload it in a jar file to
          the Guvnor and use that in place of the declarative model then
          the problem does not happen.<br>
          This is a workaround in the short term but I would much prefer
          not to have to do this.<br>
          <br>
          Chris Selwyn<br>
          <br>
          <br>
          On 01/12/2010 15:14, Chris Selwyn wrote:
          <blockquote cite="mid:4CF66655.6020902@selwyn-family.me.uk"
            type="cite">
            <meta content="text/html; charset=ISO-8859-1"
              http-equiv="Content-Type">
            <title></title>
            Yes the package is "SWWB2BOutgoing" but it looks as though
            the package name simple doesn't get reported in the log
            file.<br>
            <br>
            I have been debugging through this thing and where I've got
            to so far is that I am getting two (and maybe more) entries
            for the class "SWWB2BOutgoing.QuestionValidation" in the
            ObjectTypeConfigurationRepository.<br>
            So my current question is "How is this possible?" Is it
            maybe a classloader issue?<br>
            <br>
            Chris<br>
            <br>
            <br>
            On 01/12/2010 12:05, Wolfgang Laun wrote:
            <blockquote
              cite="mid:AANLkTikSw5dnnhU8fRcMug0gkAShN0vtv3_CW67V1R-8@mail.gmail.com"
              type="cite">A closer look:<br>
              <br>
              On 1 December 2010 11:13, Chris Selwyn <span dir="ltr">&lt;<a
                  moz-do-not-send="true"
                  href="mailto:chris@selwyn-family.me.uk">chris@selwyn-family.me.uk</a>&gt;</span>
              wrote:<br>
              <div class="gmail_quote">
                <blockquote class="gmail_quote" style="border-left: 1px
                  solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex;
                  padding-left: 1ex;"> <br>
                  <br>
                  I can see the facts being inserted in the log as
                  follows<br>
[#|2010-12-01T09:19:16.723+0000|INFO|sun-appserver2.1|javax.enterprise.system.stream.out|_ThreadID=70;_ThreadName=p:<br>
                  thread-pool-1; w: 7;|<br>
                  OBJECT ASSERTED value:QuestionValidation(
                  mandatory=true, state=Closed,<br>
                  question=B2B_METER_SERIAL_NUMBER, type=string )
                  factId: 39|#]<br>
                </blockquote>
                <div><br>
                  Shouldn't the package name appear in the log as well?<br>
                  &nbsp;</div>
                <blockquote class="gmail_quote" style="border-left: 1px
                  solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex;
                  padding-left: 1ex;"> <br>
                  However, if I insert a QuestionValidation fact created
                  in Java by using<br>
                  kbase.getFactType("SWWB2BOutgoing",
                  "QuestionValidation") then the Test<br>
                  rule gets fired just fine.<br>
                </blockquote>
                <div><br>
                  That is, apparently "SWWB2BOutgoing".<br>
                  <br>
                  -W</div>
              </div>
              <br>
              <pre wrap=""><fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
rules-users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a>
</pre>
              <br>
              <fieldset class="mimeAttachmentHeader"></fieldset>
              <br>
              <p class="avgcert" color="#000000" align="left">No virus
                found in this message.<br>
                Checked by AVG - <a moz-do-not-send="true"
                  href="http://www.avg.com">www.avg.com</a><br>
                Version: 10.0.1170 / Virus Database: 426/3290 - Release
                Date: 11/30/10</p>
            </blockquote>
            <pre wrap=""><fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
rules-users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a>
</pre>
            <br>
            <fieldset class="mimeAttachmentHeader"></fieldset>
            <br>
            <p class="avgcert" color="#000000" align="left">No virus
              found in this message.<br>
              Checked by AVG - <a moz-do-not-send="true"
                href="http://www.avg.com">www.avg.com</a><br>
              Version: 10.0.1170 / Virus Database: 426/3290 - Release
              Date: 11/30/10</p>
          </blockquote>
          <pre wrap=""><fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
rules-users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a>
</pre>
        </blockquote>
        <br>
        <pre wrap=""><fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
rules-users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a>
</pre>
        <br>
        <fieldset class="mimeAttachmentHeader"></fieldset>
        <br>
        <p class="avgcert" color="#000000" align="left">No virus found
          in this message.<br>
          Checked by AVG - <a moz-do-not-send="true"
            href="http://www.avg.com">www.avg.com</a><br>
          Version: 10.0.1170 / Virus Database: 426/3291 - Release Date:
          12/01/10</p>
      </blockquote>
    </blockquote>
    <br>
  </body>
</html>